log

package
v1.8.29 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2024 License: Apache-2.0 Imports: 6 Imported by: 169

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(v ...interface{})

func Debugf

func Debugf(format string, v ...interface{})

func Error

func Error(v ...interface{})

func Errorf

func Errorf(format string, v ...interface{})

func Fatal

func Fatal(v ...interface{})

func Fatalf

func Fatalf(format string, v ...interface{})

func Info

func Info(v ...interface{})

func Infof

func Infof(format string, v ...interface{})

func NewDefaultLogger added in v1.7.4

func NewDefaultLogger(out io.Writer, prefix string, flag int, lv Level) *defaultLogger

func Panic

func Panic(v ...interface{})

func Panicf

func Panicf(format string, v ...interface{})

func SetDummyLogger added in v1.3.1

func SetDummyLogger()

func SetLogger

func SetLogger(logger Logger)

func Warn

func Warn(v ...interface{})

func Warnf

func Warnf(format string, v ...interface{})

Types

type Level added in v1.7.4

type Level int

type of log level

const (
	LvPanic Level = iota
	LvFatal
	LvError
	LvWarn
	LvInfo
	LvDebug

	LvMax
)

log level constant

type Logger

type Logger interface {
	Debug(v ...interface{})
	Debugf(format string, v ...interface{})

	Info(v ...interface{})
	Infof(format string, v ...interface{})

	Warn(v ...interface{})
	Warnf(format string, v ...interface{})

	Error(v ...interface{})
	Errorf(format string, v ...interface{})

	Fatal(v ...interface{})
	Fatalf(format string, v ...interface{})

	Panic(v ...interface{})
	Panicf(format string, v ...interface{})
}

func GetLogger added in v1.8.10

func GetLogger() Logger

Jump to

Keyboard shortcuts

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