log

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(msg string, args ...interface{})

func DebugEnabled

func DebugEnabled() bool

func Error

func Error(msg string, args ...interface{})

func Info

func Info(msg string, args ...interface{})

func SetLevel

func SetLevel(l Level)

func Warn

func Warn(msg string, args ...interface{})

Types

type DefaultLogger

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

func (*DefaultLogger) Log

func (l *DefaultLogger) Log(level Level, msg string, args ...any)

type Level

type Level int
const (
	LevelDebug Level = iota
	LevelInfo
	LevelWarn
	LevelError
)

func GetLevel

func GetLevel() Level

type Logger

type Logger interface {
	Log(level Level, msg string, args ...any)
}

func NewLogger

func NewLogger() Logger

Jump to

Keyboard shortcuts

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