logger

package
v0.0.0-...-9678cfa Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(v ...any)

func Debugf

func Debugf(format string, v ...any)

func Error

func Error(v ...any)

func Errorf

func Errorf(format string, v ...any)

func Fatal

func Fatal(v ...any)

func Fatalf

func Fatalf(format string, v ...any)

func Info

func Info(v ...any)

func Infof

func Infof(format string, v ...any)

func SetLevel

func SetLevel(level Level)

func Warn

func Warn(v ...any)

func Warnf

func Warnf(format string, v ...any)

Types

type Level

type Level int
const (
	DEBUG Level = iota
	INFO
	WARN
	ERROR
	FATAL
)

func (Level) String

func (l Level) String() string

type Logger

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

func New

func New(prefixs ...string) *Logger

func (*Logger) Add

func (l *Logger) Add(prefix string)

func (*Logger) CloneAdd

func (l *Logger) CloneAdd(prefix string) *Logger

func (*Logger) Debug

func (l *Logger) Debug(v ...any)

func (*Logger) Debugf

func (l *Logger) Debugf(format string, v ...any)

func (*Logger) Error

func (l *Logger) Error(v ...any)

func (*Logger) Errorf

func (l *Logger) Errorf(format string, v ...any)

func (*Logger) Fatal

func (l *Logger) Fatal(v ...any)

func (*Logger) Fatalf

func (l *Logger) Fatalf(format string, v ...any)

func (*Logger) Info

func (l *Logger) Info(v ...any)

func (*Logger) Infof

func (l *Logger) Infof(format string, v ...any)

func (*Logger) Warn

func (l *Logger) Warn(v ...any)

func (*Logger) Warnf

func (l *Logger) Warnf(format string, v ...any)

Jump to

Keyboard shortcuts

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