Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Route ¶
type Route interface {
Router
Fallback(handler contractshttp.HandlerFunc)
GlobalMiddleware(middlewares ...contractshttp.Middleware)
Run(host ...string) error
RunTLS(host ...string) error
RunTLSWithCert(host, certFile, keyFile string) error
ServeHTTP(writer http.ResponseWriter, request *http.Request)
}
type Router ¶ added in v1.13.1
type Router interface {
Group(handler GroupFunc)
Prefix(addr string) Router
Middleware(middlewares ...contractshttp.Middleware) Router
Any(relativePath string, handler contractshttp.HandlerFunc)
Get(relativePath string, handler contractshttp.HandlerFunc)
Post(relativePath string, handler contractshttp.HandlerFunc)
Delete(relativePath string, handler contractshttp.HandlerFunc)
Patch(relativePath string, handler contractshttp.HandlerFunc)
Put(relativePath string, handler contractshttp.HandlerFunc)
Options(relativePath string, handler contractshttp.HandlerFunc)
Resource(relativePath string, controller contractshttp.ResourceController)
Static(relativePath, root string)
StaticFile(relativePath, filepath string)
StaticFS(relativePath string, fs http.FileSystem)
}
Click to show internal directories.
Click to hide internal directories.