Documentation ¶
Index ¶
- Constants
- func DefaultGinInit() *ginsdk.Engine
- func DefaultGinWithTrustedPlatform(trustedPlatform string) *ginsdk.Engine
- func DefaultGinWithTrustyProxy(trustyProxy []string) *ginsdk.Engine
- func GinAccessLog(log liblog.FuncLog) ginsdk.HandlerFunc
- func GinAddGlobalMiddleware(eng *ginsdk.Engine, middleware ...ginsdk.HandlerFunc) *ginsdk.Engine
- func GinEngine(trustedPlatform string, trustyProxy ...string) (*ginsdk.Engine, error)
- func GinErrorLog(log liblog.FuncLog) ginsdk.HandlerFunc
- func GinLatencyContext(c *ginsdk.Context)
- func GinRequestContext(c *ginsdk.Context)
- func Handler(routerList RouterList) http.Handler
- func RoutersHandler(engine *ginsdk.Engine)
- func RoutersRegister(method string, relativePath string, router ...ginsdk.HandlerFunc)
- func RoutersRegisterInGroup(group, method string, relativePath string, router ...ginsdk.HandlerFunc)
- func SetGinHandler(fct func(c *ginsdk.Context)) ginsdk.HandlerFunc
- type RegisterRouter
- type RegisterRouterInGroup
- type RouterList
Constants ¶
View Source
const ( ErrorParamEmpty liberr.CodeError = iota + liberr.MinPkgRouter ErrorConfigValidator ErrorHeaderAuth ErrorHeaderAuthMissing ErrorHeaderAuthEmpty ErrorHeaderAuthRequire ErrorHeaderAuthForbidden )
View Source
const ( EmptyHandlerGroup = "<nil>" GinContextStartUnixNanoTime = "gin-ctx-start-unix-nano-time" GinContextRequestPath = "gin-ctx-request-path" GinContextRequestUser = "gin-ctx-request-user" )
Variables ¶
This section is empty.
Functions ¶
func DefaultGinInit ¶ added in v1.6.0
func DefaultGinWithTrustedPlatform ¶ added in v1.7.4
func DefaultGinWithTrustyProxy ¶ added in v1.6.0
func GinAccessLog ¶ added in v1.9.8
func GinAccessLog(log liblog.FuncLog) ginsdk.HandlerFunc
func GinAddGlobalMiddleware ¶ added in v1.9.8
func GinErrorLog ¶ added in v1.9.8
func GinErrorLog(log liblog.FuncLog) ginsdk.HandlerFunc
func GinLatencyContext ¶ added in v1.9.8
func GinRequestContext ¶ added in v1.9.8
func Handler ¶
func Handler(routerList RouterList) http.Handler
func RoutersHandler ¶
func RoutersRegister ¶
func RoutersRegister(method string, relativePath string, router ...ginsdk.HandlerFunc)
func RoutersRegisterInGroup ¶
func RoutersRegisterInGroup(group, method string, relativePath string, router ...ginsdk.HandlerFunc)
func SetGinHandler ¶
func SetGinHandler(fct func(c *ginsdk.Context)) ginsdk.HandlerFunc
SetGinHandler func that return given func as ginTonic HandlerFunc interface type.
Types ¶
type RegisterRouter ¶
type RegisterRouter func(method string, relativePath string, router ...ginsdk.HandlerFunc)
type RegisterRouterInGroup ¶
type RegisterRouterInGroup func(group, method string, relativePath string, router ...ginsdk.HandlerFunc)
type RouterList ¶
type RouterList interface { Register(method string, relativePath string, router ...ginsdk.HandlerFunc) RegisterInGroup(group, method string, relativePath string, router ...ginsdk.HandlerFunc) RegisterMergeInGroup(group, method string, relativePath string, router ...ginsdk.HandlerFunc) Handler(engine *ginsdk.Engine) Engine() *ginsdk.Engine }
func NewRouterList ¶
func NewRouterList(initGin func() *ginsdk.Engine) RouterList
Source Files ¶
Click to show internal directories.
Click to hide internal directories.