Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExtendsRegisterDefaultInit ¶
func ExtendsRegisterDefaultInit(rootPath string)
ExtendsRegisterDefaultInit 扩展器初始化函数,可自定义
Types ¶
type AssembleCustomWrapHandler ¶
type AssembleCustomWrapHandler interface {
AssembleCustomWrapHandlerFunc(handlers []gin.HandlerFunc) []gin.HandlerFunc
}
type ContextPath ¶
type ContextPathDuplicateRemoval ¶
ContextPathDuplicateRemoval http://localhost:8080/v3/api-docs 获取文档信息接口paths对象去掉跟路径
type CustomGinWrapHandler ¶
type CustomGinWrapHandler interface {
CustomGinWrapFunc(handler gin.HandlerFunc) gin.HandlerFunc
}
type CustomValidatorErrorRes ¶
type ExtendsRegister ¶
type ExtendsRegister struct { Cpdr ContextPathDuplicateRemoval // swagger查询api接口时,把根路径去掉,打开swagger页面时,url根路径会重复,如果没有重复可以不启用 Vem ValidatorErrorMessages // 自定义Validator验证错误描述信息 Cgwh CustomGinWrapHandler // 自定义gin.handler包装器,默认为panic统一拦截器 Acwh AssembleCustomWrapHandler // 把每个gin.Handler包装一层自定义CustomGinWrapHandler Cver CustomValidatorErrorRes // 自定义参数验证错误响应体,默认为自定义的Result结构体 Cp ContextPath // 根路径:http://localhost:8080/example/doc.html# example为根路径 }
var ExtendsRegisterDefault ExtendsRegister
type ValidatorErrorMessages ¶
Click to show internal directories.
Click to hide internal directories.