logs

package
v0.0.0-...-483725b Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2024 License: MIT Imports: 5 Imported by: 2

Documentation

Index

Constants

View Source
const (
	LogModeDevelopment logMode = 1
	LogModeProduct     logMode = 2
)

Variables

This section is empty.

Functions

func CtxAddKVs

func CtxAddKVs(ctx context.Context, kvs ...any) context.Context

func CtxDebugKvs

func CtxDebugKvs(ctx context.Context, msg string, kvs ...any)

func CtxErrorKvs

func CtxErrorKvs(ctx context.Context, msg string, kvs ...any)

func CtxInfoKvs

func CtxInfoKvs(ctx context.Context, msg string, kvs ...any)

func CtxPanicKvs

func CtxPanicKvs(ctx context.Context, msg string, kvs ...any)

func CtxWarnKvs

func CtxWarnKvs(ctx context.Context, msg string, kvs ...any)

func DebugKvs

func DebugKvs(msg string, kvs ...any)

func ErrorKvs

func ErrorKvs(msg string, kvs ...any)

func GetAllKVs

func GetAllKVs(ctx context.Context) []any

func InfoKvs

func InfoKvs(msg string, kvs ...any)

func Init

func Init(logMode logMode, logPath string, enableColor bool)

Init logPath为空则不同时输出到文件

func PanicKvs

func PanicKvs(msg string, kvs ...any)

func Sync

func Sync()

func WarnKvs

func WarnKvs(msg string, kvs ...any)

Types

This section is empty.

Jump to

Keyboard shortcuts

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