Documentation ¶
Index ¶
Constants ¶
View Source
const Version = "v1.1.3"
Variables ¶
This section is empty.
Functions ¶
func HealthHandler ¶
func HealthHandler(healthFunction health.HealthFunc) func(ctx *gin.Context)
Health godoc @_Summary Show health service status @_Produce json @_Success 200 {string} nil "" @_Failure 400 {object} fault.TypedErrorStr "" @_Failure 404 {object} fault.TypedErrorStr "" @_Failure 500 {object} fault.TypedErrorStr "" @_Router /health [get]
func RedirectToApiHandler ¶
func RedirectToApiHandler(RouterGroup *gin.RouterGroup)
func ShowVersion ¶
func ShowVersion() string
Types ¶
type AbstractComponent ¶
type BaseComponent ¶
type BaseComponent struct { AbstractComponent Address string FactoryGinRouter factory_gin.FactoryGinRouter FactoryRestClient factory_restclient.FactoryRestClient FactoryLogger factory_logger.FactoryLogger FactoryRedis factory_redis.FactoryRedis FactoryCache factory_cache.FactoryCache FactoryOAuth factory_oauth.FactoryOAuth FactoryGormSource factory_gormsource.FactoryGormSource FactorySwagger factory_swagger.FactorySwagger FactoryKafka factory_kafka.FactoryKafka FactoryDataSource factory_datasource.FactoryDataSource FactoryRedirect factory_redirect.FactoryRedirect ApiVersion string // contains filtered or unexported fields }
func (*BaseComponent) InitBaseComponent ¶
func (this *BaseComponent) InitBaseComponent( serviceName string, version string, swaggerInfo *SI, )
func (*BaseComponent) PostConstructComponent ¶
func (this *BaseComponent) PostConstructComponent( serviceName string, swaggerInfo *SI, router Router, healthFunction health.HealthFunc, )
func (*BaseComponent) RedirectToApi ¶
func (this *BaseComponent) RedirectToApi(ctx *gin.Context)
type BaseRouter ¶
type BaseRouter struct { Router *gin.Engine RouterGroup *gin.RouterGroup Filters []gin.HandlerFunc }
func (*BaseRouter) AddFilter ¶
func (this *BaseRouter) AddFilter(handlers ...gin.HandlerFunc)
func (*BaseRouter) Get ¶
func (this *BaseRouter) Get(relativePath string, handlers ...gin.HandlerFunc)
func (BaseRouter) GetEngine ¶
func (this BaseRouter) GetEngine() *gin.Engine
func (*BaseRouter) GetRouterGroup ¶
func (this *BaseRouter) GetRouterGroup() *gin.RouterGroup
type Router ¶
type Router interface { Get(relativePath string, handlers ...gin.HandlerFunc) GetEngine() *gin.Engine GetRouterGroup() *gin.RouterGroup AddFilter(handlers ...gin.HandlerFunc) InitRouter() }
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
factory
|
|
Типы были выделенны для того чтобы в списке аргументов избежать несовпадний из за однотипности
|
Типы были выделенны для того чтобы в списке аргументов избежать несовпадний из за однотипности |
Click to show internal directories.
Click to hide internal directories.