log

package
v0.0.0-...-fdc8e6b Latest Latest
Warning

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

Go to latest
Published: May 13, 2022 License: Unlicense Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewZapProd

func NewZapProd() (*zap.Logger, error)

Types

type BuiltinLogger

type BuiltinLogger struct {
	*std_log.Logger
	Level int
	Null  bool
}

func NewBuiltinLogger

func NewBuiltinLogger(level int) *BuiltinLogger

func (*BuiltinLogger) Debug

func (bl *BuiltinLogger) Debug(args ...interface{})

func (*BuiltinLogger) Debugf

func (bl *BuiltinLogger) Debugf(template string, args ...interface{})

func (*BuiltinLogger) Error

func (bl *BuiltinLogger) Error(args ...interface{})

func (*BuiltinLogger) Errorf

func (bl *BuiltinLogger) Errorf(template string, args ...interface{})

func (*BuiltinLogger) Info

func (bl *BuiltinLogger) Info(args ...interface{})

func (*BuiltinLogger) Infof

func (bl *BuiltinLogger) Infof(template string, args ...interface{})

func (*BuiltinLogger) Named

func (bl *BuiltinLogger) Named(name string)

func (*BuiltinLogger) Warn

func (bl *BuiltinLogger) Warn(args ...interface{})

func (*BuiltinLogger) Warnf

func (bl *BuiltinLogger) Warnf(template string, args ...interface{})

func (*BuiltinLogger) With

func (bl *BuiltinLogger) With(args ...interface{}) Logger

type Logger

type Logger interface {
	//Named(name string)
	Debug(args ...interface{})
	Debugf(template string, args ...interface{})

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

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

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

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

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

	With(args ...interface{}) Logger
}

type LoggerWithWarning

type LoggerWithWarning interface {
	Logger

	Warning(args ...interface{})
	Warningf(template string, args ...interface{})
}

func NewShimLoggerWarning

func NewShimLoggerWarning(logger Logger) LoggerWithWarning

type ShimLoggerWarning

type ShimLoggerWarning struct {
	Logger
}

func (*ShimLoggerWarning) Warning

func (sl *ShimLoggerWarning) Warning(args ...interface{})

func (*ShimLoggerWarning) Warningf

func (sl *ShimLoggerWarning) Warningf(template string, args ...interface{})

type ZapLogger

type ZapLogger struct {
	Sugar *zap.SugaredLogger
}

func NewZapLogger

func NewZapLogger(_logger *zap.Logger) *ZapLogger

func (*ZapLogger) Debug

func (zl *ZapLogger) Debug(args ...interface{})

func (*ZapLogger) Debugf

func (zl *ZapLogger) Debugf(template string, args ...interface{})

func (*ZapLogger) Error

func (zl *ZapLogger) Error(args ...interface{})

func (*ZapLogger) Errorf

func (zl *ZapLogger) Errorf(template string, args ...interface{})

func (*ZapLogger) Fatal

func (zl *ZapLogger) Fatal(args ...interface{})

func (*ZapLogger) Fatalf

func (zl *ZapLogger) Fatalf(template string, args ...interface{})

func (*ZapLogger) Info

func (zl *ZapLogger) Info(args ...interface{})

func (*ZapLogger) Infof

func (zl *ZapLogger) Infof(template string, args ...interface{})

func (*ZapLogger) Panic

func (zl *ZapLogger) Panic(args ...interface{})

func (*ZapLogger) Panicf

func (zl *ZapLogger) Panicf(template string, args ...interface{})

func (*ZapLogger) Warn

func (zl *ZapLogger) Warn(args ...interface{})

func (*ZapLogger) Warnf

func (zl *ZapLogger) Warnf(template string, args ...interface{})

func (*ZapLogger) With

func (zl *ZapLogger) With(args ...interface{}) Logger

Jump to

Keyboard shortcuts

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