Documentation
¶
Index ¶
Constants ¶
View Source
const ( // LevelMsg is generic message log level LevelMsg = iota // LevelError is errors log level LevelError // LevelSuccess is success log level LevelSuccess // LevelWarn is warning log level LevelWarn // LevelInfo is info message log level LevelInfo // LevelDebug is debug messages log level LevelDebug )
Variables ¶
View Source
var Default sdk.Logger
Default is default logger instance
Functions ¶
func UseConsoleLogger ¶
UseConsoleLogger bootstraps console logger as default log instance
func UseTestLogger ¶ added in v0.9.0
UseTestLogger inits test logger
Types ¶
type Formatter ¶
type Formatter interface {
// Next returns a new instance of formatter for sub-logger
Next() Formatter
// Format formats log message
Format(format string, args ...interface{}) string
// WrapString wraps log string
WrapString(str string) string
// WrapMultiline wraps multiline string
WrapMultiline(str string) (out string)
}
Formatter formats log messages
Click to show internal directories.
Click to hide internal directories.