Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Handler ¶
type Handler struct { Path string `yaml:"path"` Type string `yaml:"type"` Config map[string]string `yaml:"config"` }
Handler - A handler represents an HTTP handler listening to a path and having a type and its own configuration.
type Middleware ¶
Middleware - A middlware represents an HTTP middleware having a type and its own configuration.
type Router ¶
type Router struct { Prefix string `yaml:"prefix"` Middlewares []Middleware `yaml:"middlewares"` Handlers []Handler `yaml:"handlers"` }
Router - A router contains a prefix-defined routing rule, and underlying middlewares and handlers.
Click to show internal directories.
Click to hide internal directories.