handler

package
Version: v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

Handler represent Handler

func NewHandler

func NewHandler() (*Handler, error)

NewHandler new Handler

func (*Handler) GetCacher added in v0.2.1

func (h *Handler) GetCacher(cName string) (*cacher.Cacher, error)

GetCacher get Cacher

func (*Handler) GetCachers added in v0.2.1

func (h *Handler) GetCachers() map[string]*cacher.Cacher

GetCachers get Cachers

func (*Handler) GetCasbinEnforcer added in v0.2.0

func (h *Handler) GetCasbinEnforcer(ceName string) (*casbin.Enforcer, error)

GetCasbinEnforcer get CasbinEnforcer

func (*Handler) GetConfig

func (h *Handler) GetConfig() (*config.Config, error)

GetConfig get Config

func (*Handler) GetGormDB

func (h *Handler) GetGormDB(conName string) (*gorm.DB, error)

GetGormDB get GORM database connection by connection name

func (*Handler) GetGormDBs added in v0.2.0

func (h *Handler) GetGormDBs() map[string]*gorm.DB

GetGormDBs get Gorm Databases

func (*Handler) SetCacher added in v0.2.1

func (h *Handler) SetCacher(cName string, c *cacher.Cacher)

SetCacher set Cacher

func (*Handler) SetCasbinEnforcer added in v0.2.0

func (h *Handler) SetCasbinEnforcer(ceName string, ce *casbin.Enforcer)

SetCasbinEnforcer set CasbinEnforcer

func (*Handler) SetConfig

func (h *Handler) SetConfig(config *config.Config)

SetConfig set Config

func (*Handler) SetGormDB

func (h *Handler) SetGormDB(conName string, dbCon *gorm.DB)

SetGormDB set GORM database connection by connection name

Source Files

Jump to

Keyboard shortcuts

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