Documentation ¶
Index ¶
Constants ¶
View Source
const TimeFormat = "2006-01-02T15:04:05.999Z07:00"
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Level ¶ added in v1.20.0
type Level string
func DefaultLevel ¶ added in v1.20.0
func DefaultLevel() Level
type LevelRanks ¶ added in v1.20.0
func DefaultLevelRanks ¶ added in v1.20.0
func DefaultLevelRanks() LevelRanks
type Logger ¶
type Logger interface { Log(level Level, message string) Debug(message string) Info(message string) Warn(message string) Error(message string) Debugf(message string, args ...interface{}) Infof(message string, args ...interface{}) Warnf(message string, args ...interface{}) Errorf(message string, args ...interface{}) WithError(err error) Logger WithField(key string, value interface{}) Logger WithFields(fields Fields) Logger WithLevelRank(level Level, rank Rank) Logger WithLevelRanks(levelRanks LevelRanks) Logger WithLevel(level Level) Logger Level() Level }
func LoggerFromContext ¶ added in v1.20.0
func NewLogger ¶
func NewLogger(serializer Serializer, levelRanks LevelRanks, level Level) (Logger, error)
type Serializer ¶ added in v1.20.0
Click to show internal directories.
Click to hide internal directories.