Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Group ¶
type Group struct { // Routes in the group Routes []Route // Set of middlewares to be applied to the routes. If a route already has its pipeline, group's pipeline will wrap it Pipeline Pipeline }
Group struct represents a group of routes. Pipeline middlewares will be applied to all routes in the group
type Middleware ¶
type Middleware func(next httprouter.Handle) httprouter.Handle
Middleware wraps the next handler
type Route ¶
type Route struct { // Path Path string // Handle function Handler httprouter.Handle // Method verb Method string // Set of middlewares to be applied to the routes Pipeline Pipeline }
Route struct for representing a route
type Router ¶
type Router struct {
*httprouter.Router
}
Router wrapper for httprouter.Router
func NewDefaultRouter ¶
Click to show internal directories.
Click to hide internal directories.