svc

package
v0.0.0-...-f4de95a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 15, 2023 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitStruct

func InitStruct(s interface{}, initFn func(name string, i interface{}) error) error

/ InitStruct reflect fields in struct and run initializer function

func SetupRoute

func SetupRoute(router *gin.Engine, controllers *Controllers) *gin.Engine

Types

type App

type App struct {
	*contract.AppContract
}

func NewAPI

func NewAPI(config *contract.Config) (*App, error)

func (*App) Boot

func (a *App) Boot() error

func (*App) CORS

func (app *App) CORS(r *gin.Engine, configCORS string) (*gin.Engine, error)

func (*App) InitRouter

func (app *App) InitRouter(workDir string) (*gin.Engine, error)

func (*App) SetSecureHTTP

func (app *App) SetSecureHTTP(r *gin.Engine, config *contract.Config) *gin.Engine

func (*App) SetTrustProxies

func (app *App) SetTrustProxies(r *gin.Engine, trustProxy string) (*gin.Engine, error)

type Controllers

type Controllers struct {
	GetHealth *controller.GetHealthController
}

func NewController

func NewController(a *App) *Controllers

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL