zerolog

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2018 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultFactory

func DefaultFactory(lvl log.Level) log.Factory

DefaultFactory returns a zero logger factory with default settings

func NewFactory

func NewFactory(l *zerolog.Logger, lvl log.Level) log.Factory

NewFactory returns a new zero logger factory

func NewLogger

func NewLogger(l *zerolog.Logger, lvl log.Level, f map[string]interface{}) log.Logger

NewLogger returns a new logger

Types

type Factory

type Factory struct {
	// contains filtered or unexported fields
}

Factory of the zero logger

func (*Factory) Create

func (zf *Factory) Create(f map[string]interface{}) log.Logger

Create a zero logger

func (*Factory) CreateSub

func (zf *Factory) CreateSub(logger log.Logger, fields map[string]interface{}) log.Logger

CreateSub a zero sub logger with defined fields

type Logger

type Logger struct {
	// contains filtered or unexported fields
}

Logger implements logging with zerolog

func (Logger) Debug

func (zl Logger) Debug(args ...interface{})

Debug logging

func (Logger) Debugf

func (zl Logger) Debugf(msg string, args ...interface{})

Debugf logging

func (Logger) Error

func (zl Logger) Error(args ...interface{})

Error logging

func (Logger) Errorf

func (zl Logger) Errorf(msg string, args ...interface{})

Errorf logging

func (Logger) Fatal

func (zl Logger) Fatal(args ...interface{})

Fatal logging

func (Logger) Fatalf

func (zl Logger) Fatalf(msg string, args ...interface{})

Fatalf logging

func (Logger) Fields

func (zl Logger) Fields() map[string]interface{}

Fields returns the fields associated with this logger

func (Logger) Info

func (zl Logger) Info(args ...interface{})

Info logging

func (Logger) Infof

func (zl Logger) Infof(msg string, args ...interface{})

Infof logging

func (Logger) Level

func (zl Logger) Level() log.Level

Level returns the minimum level.

func (Logger) Panic

func (zl Logger) Panic(args ...interface{})

Panic logging

func (Logger) Panicf

func (zl Logger) Panicf(msg string, args ...interface{})

Panicf logging

func (Logger) Warn

func (zl Logger) Warn(args ...interface{})

Warn logging

func (Logger) Warnf

func (zl Logger) Warnf(msg string, args ...interface{})

Warnf logging

Jump to

Keyboard shortcuts

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