Documentation
¶
Index ¶
- func DPanicw(msg string, keysAndValues ...interface{})
- func Debugf(format string, args ...interface{})
- func Debugw(msg string, keysAndValues ...interface{})
- func Errorf(format string, args ...interface{})
- func Errorw(msg string, keysAndValues ...interface{})
- func Fatalf(format string, args ...interface{})
- func Fatalw(msg string, keysAndValues ...interface{})
- func Infof(format string, args ...interface{})
- func Infow(msg string, keysAndValues ...interface{})
- func NewLogSink() (*zap.Logger, error)
- func Panicf(format string, args ...interface{})
- func Panicw(msg string, keysAndValues ...interface{})
- func Printf(format string, args ...interface{})
- func RedirectStdLog(l Logger) (func(), error)
- func Warnf(format string, args ...interface{})
- func Warnw(msg string, keysAndValues ...interface{})
- type LogFunc
- type Logger
- type Opt
- type Opts
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RedirectStdLog ¶ added in v0.5.6
RedirectStdLog is redirecting the standard logger to the logger.
Types ¶
type LogFunc ¶ added in v0.5.1
type LogFunc func(string, ...interface{})
LogFunc is a bridge between Logger and any third party logger.
type Logger ¶
type Logger interface { // Log a notice statement Noticef(format string, v ...interface{}) // Infof is logging an info statement. Infof(format string, v ...interface{}) // Log a warning statement Warnf(format string, v ...interface{}) // Log a fatal error Fatalf(format string, v ...interface{}) // Log an error Errorf(format string, v ...interface{}) // Log a debug statement Debugf(format string, v ...interface{}) // Log a trace statement Tracef(format string, v ...interface{}) // Panicf is logging a panic statement. Panicf(format string, v ...interface{}) // Printf is logging a printf statement. Printf(format string, v ...interface{}) // Debugw is logging a debug statement with context. Debugw(msg string, keysAndValues ...interface{}) // Infow is logging an info statement with context. Infow(msg string, keysAndValues ...interface{}) // Warnw is logging a warning statement with context. Warnw(msg string, keysAndValues ...interface{}) // Errorw is logging an error statement with context. Errorw(msg string, keysAndValues ...interface{}) // DPanicw is logging a debug panic statement with context. DPanicw(msg string, keysAndValues ...interface{}) // Panicw is logging a panic statement with context. Panicw(msg string, keysAndValues ...interface{}) // Fatalw is logging a fatal statement with context. Fatalw(msg string, keysAndValues ...interface{}) }
Logger represents a standard logging interface.
var LogSink Logger
LogSink is the logger sink.
type Opt ¶
type Opt func(*Opts)
Opt is a logger option.
func WithLogger ¶ added in v0.5.6
WithLogger is setting the logger.
Click to show internal directories.
Click to hide internal directories.