plugin

package
v3.0.0-...-7237cd1 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UserKey     = "user"
	PasswordKey = "password"
)

Variables

This section is empty.

Functions

func Auth

func Auth(errHandler func(c *gin.Context, code int, err error)) func(c *gin.Context)

func GetAuth

func GetAuth(c *gin.Context) (user, password string, err error)

func Init

func Init(r gin.IRouter)

func Register

func Register(plugin Plugin)

func RegisterGenerateAuth

func RegisterGenerateAuth(r gin.IRouter)

func Start

func Start()

func Stop

func Stop()

func StopWithCtx

func StopWithCtx(ctx context.Context)

Types

type Plugin

type Plugin interface {
	Init(r gin.IRouter) error
	Start() error
	Stop() error
	String() string
	Version() string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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