gin

package
v1.18.0 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2025 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GinTonic

type GinTonic interface {
	context.Context

	//generic
	GinContext() *ginsdk.Context
	CancelOnSignal(s ...os.Signal)

	//gin context metadata
	Set(key any, value any)
	Get(key any) (value any, exists bool)
	MustGet(key any) any
	GetString(key any) (s string)
	GetBool(key any) (b bool)
	GetInt(key any) (i int)
	GetInt64(key any) (i64 int64)
	GetFloat64(key any) (f64 float64)
	GetTime(key any) (t time.Time)
	GetDuration(key any) (d time.Duration)
	GetStringSlice(key any) (ss []string)
	GetStringMap(key any) (sm map[string]any)
	GetStringMapString(key any) (sms map[string]string)
	GetStringMapStringSlice(key any) (smss map[string][]string)

	SetLogger(log liblog.FuncLog)
}

func New added in v1.18.0

func New(c *ginsdk.Context, log liblog.FuncLog) GinTonic

Jump to

Keyboard shortcuts

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