Documentation ¶
Index ¶
- func WrapBody[Req any](bizFn func(ctx *gin.Context, req Req) (Result, error)) gin.HandlerFunc
- func WrapNoParam(bizFn func(ctx *gin.Context) (Result, error)) gin.HandlerFunc
- func WrapParam[Req any](bizFn func(ctx *gin.Context, req Req) (Result, error)) gin.HandlerFunc
- func WrapQuery[Req any](bizFn func(ctx *gin.Context, req Req) (Result, error)) gin.HandlerFunc
- type Result
- type TokenResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WrapNoParam ¶
WrapNoParam 是一个中间件,用于包裹不需要请求参数的业务逻辑函数,处理响应并集中管理错误处理。
Types ¶
Click to show internal directories.
Click to hide internal directories.