log

package
v0.0.0-...-d098e83 Latest Latest
Warning

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

Go to latest
Published: May 23, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LevelOff    int = 0 //关闭
	LevelEmerg  int = 1
	LevelCrit   int = 2
	LevelError  int = 3
	LevelWarn   int = 4
	LevelNotice int = 5
	LevelInfo   int = 6
	LevelDebug  int = 7
	LevelTrace  int = 8
	LevelOn     int = 9 //9 全部打开
)

日志等级

Variables

This section is empty.

Functions

This section is empty.

Types

type Log

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

Log 日志

func (*Log) Crit

func (p *Log) Crit(v ...interface{})

Crit 临界日志

func (*Log) Debug

func (p *Log) Debug(v ...interface{})

Debug 调试日志

func (*Log) Emerg

func (p *Log) Emerg(v ...interface{})

Emerg 不可用日志

func (*Log) Error

func (p *Log) Error(v ...interface{})

Error 错误日志

func (*Log) Info

func (p *Log) Info(v ...interface{})

Info 报告日志

func (*Log) Init

func (p *Log) Init(absPath, namePrefix string) (err error)

Init 初始化 name:日志前缀名称

func (*Log) Notice

func (p *Log) Notice(v ...interface{})

Notice 公告日志

func (*Log) SetLevel

func (p *Log) SetLevel(level int)

SetLevel 设置日志等级

func (*Log) Stop

func (p *Log) Stop()

停止

func (*Log) Trace

func (p *Log) Trace(v ...interface{})

Trace 踪迹日志

func (*Log) Warn

func (p *Log) Warn(v ...interface{})

Warn 警告日志

Jump to

Keyboard shortcuts

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