Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Claw ¶
type Claw struct {
Handlers []MiddleWare
}
Claw is the array of the Global Middleware
func (*Claw) Merge ¶
func (c *Claw) Merge(h http.Handler) *ClawHandler
Merge all the global middleware with the provided http.HandlerFunc
func (*Claw) Use ¶
func (c *Claw) Use(h http.HandlerFunc) *ClawHandler
Use, merge all the global middleware with the provided http.HandlerFunc
type ClawFunc ¶
type ClawFunc func(rw http.ResponseWriter, req *http.Request)
ClawFunc redefine http.HandlerFunc
type ClawHandler ¶
CalwHandler only wrap a http.Handler
func (*ClawHandler) Add ¶
func (c *ClawHandler) Add(m ...interface{}) *ClawHandler
Add some middleware to a particular handler
func (*ClawHandler) Stack ¶
func (c *ClawHandler) Stack(stk ...Stack) *ClawHandler
Stack takes a Stack type variable and use it on the ClawHandler who call the function.
type MiddleWare ¶
Middleware is the signature of a valid middleware with Claw
Click to show internal directories.
Click to hide internal directories.