Documentation ¶
Index ¶
- type MiddlewareFunc
- type RouteCfg
- type RouteOpt
- func Handler(h http.Handler) RouteOpt
- func Header(headers ...string) RouteOpt
- func Host(host string) RouteOpt
- func Method(methods ...string) RouteOpt
- func Pattern(pattern string) RouteOpt
- func Prefix(prefix string) RouteOpt
- func Query(queries ...string) RouteOpt
- func Schema(schemas ...string) RouteOpt
- type Server
- func (srv *Server) Close() <-chan struct{}
- func (srv *Server) Route(opts ...RouteOpt)
- func (srv *Server) Serve(ctx context.Context) error
- func (srv *Server) ServeHTTP(w http.ResponseWriter, req *http.Request)
- func (srv *Server) Serving() <-chan struct{}
- func (srv *Server) Shutdown(ctx context.Context) error
- type ServerOpt
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
type ServerOpt ¶
type ServerOpt func(*Server)
func HTTPHandler ¶ added in v1.0.2
func Middleware ¶ added in v1.0.7
func Middleware(m MiddlewareFunc) ServerOpt
Click to show internal directories.
Click to hide internal directories.