Documentation ¶
Index ¶
- Constants
- type Field
- type Level
- type LevelEnablerFunc
- type Logger
- func (l *Logger) DPanic(msg string, fields ...Field)
- func (l *Logger) Debug(msg string, fields ...Field)
- func (l *Logger) Error(msg string, fields ...Field)
- func (l *Logger) Fatal(msg string, fields ...Field)
- func (l *Logger) Info(msg string, fields ...Field)
- func (l *Logger) Panic(msg string, fields ...Field)
- func (l *Logger) Warn(msg string, fields ...Field)
- type Option
- type RotateOption
- type TeeOption
- type TeeRotateOption
Constants ¶
View Source
const ( DebugLevel = zap.DebugLevel // -1 InfoLevel = zap.InfoLevel // 0, default level WarnLevel = zap.WarnLevel // 1 ErrorLevel = zap.ErrorLevel // 2 DPanicLevel = zap.DPanicLevel // 3, used in development log PanicLevel = zap.PanicLevel // 4 logs a message, then panics FatalLevel = zap.FatalLevel // 5 logs a message, then calls os.Exit(1) )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LevelEnablerFunc ¶
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
func NewTeeWithRotate ¶
func NewTeeWithRotate(tops []TeeRotateOption, opts ...Option) *Logger
type RotateOption ¶
type TeeOption ¶
type TeeOption struct { W io.Writer Lef LevelEnablerFunc }
type TeeRotateOption ¶
type TeeRotateOption struct { Filename string Rop RotateOption Lef LevelEnablerFunc }
Click to show internal directories.
Click to hide internal directories.