log

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2023 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(args ...interface{})

Debug debug

func Debugf

func Debugf(format string, args ...interface{})

Debugf debug

func Error

func Error(args ...interface{})

Error error

func Errorf

func Errorf(format string, args ...interface{})

Errorf error

func Fatal

func Fatal(args ...interface{})

Fatal fatal

func Fatalf

func Fatalf(format string, args ...interface{})

Fatalf fatal

func Info

func Info(args ...interface{})

Info info

func Infof

func Infof(format string, args ...interface{})

Infof info

func Panic

func Panic(args ...interface{})

Panic panic

func Panicf

func Panicf(format string, args ...interface{})

Panicf panic

func Print

func Print(args ...interface{})

Print print

func Printf

func Printf(format string, args ...interface{})

Printf print

func Warn

func Warn(args ...interface{})

Warn warn

func Warnf

func Warnf(format string, args ...interface{})

Warnf warn

func Warning

func Warning(args ...interface{})

Warning warn

func Warningf

func Warningf(format string, args ...interface{})

Warningf warning

Types

type Fields

type Fields map[string]interface{}

Fields alias to logrus.Fields

type Logger

type Logger interface {
	Printf(format string, args ...interface{})
	Debugf(format string, args ...interface{})
	Infof(format string, args ...interface{})
	Warnf(format string, args ...interface{})
	Warningf(format string, args ...interface{})
	Errorf(format string, args ...interface{})
	Fatalf(format string, args ...interface{})
	Panicf(format string, args ...interface{})

	Print(args ...interface{})
	Debug(args ...interface{})
	Info(args ...interface{})
	Warn(args ...interface{})
	Warning(args ...interface{})
	Error(args ...interface{})
	Fatal(args ...interface{})
	Panic(args ...interface{})

	WithFields(Fields) Logger

	// Output set output writer
	Output(io.Writer) Logger
}

Logger interface of log

func Output

func Output(w io.Writer) Logger

Output set log output

func WithFields

func WithFields(fields Fields) Logger

WithFields add extra fields

Jump to

Keyboard shortcuts

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