Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type SliceGroup ¶
type SliceGroup struct { *SliceRouter // contains filtered or unexported fields }
SliceGroup Group 结构体
func (*SliceGroup) Use ¶
func (g *SliceGroup) Use(middlewares ...HandlerFunc) *SliceGroup
Use 构造回调方法
type SliceRouter ¶
type SliceRouter struct {
// contains filtered or unexported fields
}
SliceRouter router 结构体
type SliceRouterContext ¶
type SliceRouterContext struct { Rw http.ResponseWriter Req *http.Request Ctx context.Context *SliceGroup // contains filtered or unexported fields }
SliceRouterContext router 上下文
func (*SliceRouterContext) Get ¶
func (c *SliceRouterContext) Get(key interface{}) interface{}
Get 获取上下文属性值
func (*SliceRouterContext) IsAborted ¶
func (c *SliceRouterContext) IsAborted() bool
IsAborted 是否跳过了回调
func (*SliceRouterContext) Set ¶
func (c *SliceRouterContext) Set(key, val interface{})
Set 设置上下文属性值
type SliceRouterHandler ¶
type SliceRouterHandler struct {
// contains filtered or unexported fields
}
SliceRouterHandler xx
func NewSliceRouterHandler ¶
func NewSliceRouterHandler(coreFunc func(*SliceRouterContext) http.Handler, router *SliceRouter) *SliceRouterHandler
NewSliceRouterHandler xx
func (*SliceRouterHandler) ServeHTTP ¶
func (w *SliceRouterHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request)
ServeHTTP xx
Click to show internal directories.
Click to hide internal directories.