Documentation ¶
Index ¶
Constants ¶
View Source
const ( DefaultAddr = "localhost" DefaultPort = 8080 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
func NewServerConfig ¶
func NewServerConfig() *Config
type HttpServer ¶
func NewServer ¶
func NewServer(conf *Config) *HttpServer
func (*HttpServer) Init ¶
func (serv *HttpServer) Init(initRoutes func()) error
func (*HttpServer) SetMiddleware ¶
func (serv *HttpServer) SetMiddleware(mw MiddlewareFunc) *HttpServer
func (*HttpServer) Up ¶
func (serv *HttpServer) Up() error
type MiddlewareFunc ¶
type MiddlewareFunc func() gin.HandlerFunc
Click to show internal directories.
Click to hide internal directories.