logger

package
v0.11.2 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Labeled

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

func (*Labeled) Debug

func (l *Labeled) Debug(msg string, args ...interface{})

func (*Labeled) Error

func (l *Labeled) Error(msg string, args ...interface{})

func (*Labeled) Flush

func (l *Labeled) Flush()

func (*Labeled) Info

func (l *Labeled) Info(msg string, args ...interface{})

func (*Labeled) WithLabel

func (l *Labeled) WithLabel(label string) Logger

type Logger

type Logger interface {
	WithLabel(label string) Logger
	Debug(msg string, args ...interface{})
	Info(msg string, args ...interface{})
	Error(msg string, args ...interface{})
	Flush()
}

type Noop

type Noop struct{}

func NewNoop

func NewNoop() Noop

func (Noop) Debug

func (l Noop) Debug(msg string, args ...interface{})

func (Noop) Error

func (l Noop) Error(msg string, args ...interface{})

func (Noop) Flush

func (l Noop) Flush()

func (Noop) Info

func (l Noop) Info(msg string, args ...interface{})

func (Noop) WithLabel

func (l Noop) WithLabel(label string) Logger

type Root

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

func MustNewFileRoot

func MustNewFileRoot(path string) *Root

func MustNewFileRootTruncated added in v0.9.0

func MustNewFileRootTruncated(path string) *Root

func NewFileRoot

func NewFileRoot(path string) (*Root, error)

func NewRoot

func NewRoot(out io.WriteCloser) *Root

func (*Root) Debug

func (l *Root) Debug(msg string, args ...interface{})

func (*Root) Error

func (l *Root) Error(msg string, args ...interface{})

func (*Root) Flush

func (l *Root) Flush()

func (*Root) Info

func (l *Root) Info(msg string, args ...interface{})

func (*Root) WithLabel

func (l *Root) WithLabel(label string) Logger

Jump to

Keyboard shortcuts

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