logger

package module
v0.0.0-...-3ce5ef0 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2020 License: MIT Imports: 11 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(v ...interface{})

func Error

func Error(v ...interface{})

func Fatal

func Fatal(v ...interface{})

func GetLogger

func GetLogger() (l *logger)

func Info

func Info(v ...interface{})

func SetConsole

func SetConsole(isConsole bool)

func SetFormat

func SetFormat(logFormat string)

func SetLevel

func SetLevel(_level LEVEL)

func SetLevelFile

func SetLevelFile(level LEVEL, dir, fileName string)

func SetRollingDaily

func SetRollingDaily(fileDir, fileName string)

func SetRollingFile

func SetRollingFile(fileDir, fileName string, maxNumber int32, maxSize int64, _unit UNIT)

func Warn

func Warn(v ...interface{})

Types

type LEVEL

type LEVEL int32
const (
	ALL LEVEL = iota
	DEBUG
	INFO
	WARN
	ERROR
	FATAL
	OFF
)

type UNIT

type UNIT int64
const (
	KB UNIT = 1 << (iota * 10)
	MB
	GB
	TB
)

Jump to

Keyboard shortcuts

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