logs

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Zap = Name("zap")

	LevelFatal = Level("fatal")
	LevelError = Level("error")
	LevelPanic = Level("panic")
	LevelWarn  = Level("warn")
	LevelInfo  = Level("info")
	LevelDebug = Level("debug")
)

Variables

This section is empty.

Functions

func Debug

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

func Error

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

func Fatal

func Fatal(template string, args ...interface{})

func Info

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

func Panic

func Panic(template string, args ...interface{})

func SetByName

func SetByName(name Name, level Level, timeformat string) func() error

func SetLogger

func SetLogger(l Logger)

func Warn

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

Types

type Level

type Level string

type Logger

type Logger interface {
	SetLevel(string)

	Fatal(template string, args ...interface{})
	Error(template string, args ...interface{})
	Panic(template string, args ...interface{})
	Warn(template string, args ...interface{})
	Info(template string, args ...interface{})
	Debug(template string, args ...interface{})
}

type Name

type Name string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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