1
0
mirror of https://github.com/kataras/iris.git synced 2026-01-25 21:05:56 +00:00

add Party.HandleServer and macro.IsMacro methods

This commit is contained in:
Gerasimos (Makis) Maropoulos
2023-12-06 01:09:43 +02:00
parent 6e8228596d
commit 7d540f580d
6 changed files with 121 additions and 2 deletions

View File

@@ -393,6 +393,17 @@ type Party interface {
// Connect
// Trace
Any(registeredPath string, handlers ...context.Handler) []*Route
// HandleServer registers a route for all HTTP methods which forwards the requests to the given server.
//
// Usage:
//
// app.HandleServer("/api/identity/{first:string}/orgs/{second:string}/{p:path}", otherApp)
//
// OR
//
// app.HandleServer("/api/identity", otherApp)
HandleServer(path string, server ServerHandler)
// CreateRoutes returns a list of Party-based Routes.
// It does NOT registers the route. Use `Handle, Get...` methods instead.
// This method can be used for third-parties Iris helpers packages and tools