Documentation ¶
Index ¶
- Constants
- Variables
- func Close() error
- func Debug(message string, field ...Field)
- func Debugf(format string, args ...interface{})
- func Error(message string, fields ...Field)
- func Errorf(format string, args ...interface{})
- func Fatal(message string, fields ...Field)
- func Fatalf(format string, args ...interface{})
- func Info(message string, fields ...Field)
- func Infof(format string, args ...interface{})
- func SetLevel(level Level)
- func Warn(message string, fields ...Field)
- func Warnf(format string, args ...interface{})
- type Base
- type Field
- type Level
- type Logger
- type Option
Constants ¶
View Source
const ( DebugLevel = zapcore.DebugLevel InfoLevel = zapcore.InfoLevel WarnLevel = zapcore.WarnLevel ErrorLevel = zapcore.ErrorLevel FatalLevel = zapcore.FatalLevel )
Variables ¶
View Source
var ( Binary = zap.Binary ByteString = zap.ByteString ByteStrings = zap.ByteStrings Bool = zap.Bool Float64 = zap.Float64 Float32 = zap.Float32 Int = zap.Int Int64 = zap.Int64 Int32 = zap.Int32 Int16 = zap.Int16 Int8 = zap.Int8 String = zap.String Uint = zap.Uint Uint64 = zap.Uint64 Uint32 = zap.Uint32 Uint16 = zap.Uint16 Uint8 = zap.Uint8 Namespace = zap.Namespace Stringer = zap.Stringer Time = zap.Time Duration = zap.Duration Reflect = zap.Reflect Err = zap.Error Any = zap.Any Fields = zap.Fields AddCallerSkip = zap.AddCallerSkip WithCaller = zap.WithCaller AddCaller = zap.AddCaller )
Functions ¶
Types ¶
type Level ¶
func LevelFromString ¶
type Logger ¶
type Logger interface { Debugf(format string, args ...interface{}) Infof(format string, args ...interface{}) Warnf(format string, args ...interface{}) Errorf(format string, args ...interface{}) Fatalf(format string, args ...interface{}) Debug(message string, fields ...Field) Info(message string, fields ...Field) Warn(message string, fields ...Field) Error(message string, fields ...Field) Fatal(message string, fields ...Field) With(options ...Option) Logger Unwrap() *Base }
Logger is an abstraction over various log destinations.
Click to show internal directories.
Click to hide internal directories.