logger

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 3, 2021 License: MIT Imports: 1 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LogLevel

type LogLevel int

LogLevel type

const (
	// LogLevel [Info:Debug]
	Info LogLevel = iota
	Debug
)

type Logger

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

Logger struct defines the loggrus object instance

func NewLogger

func NewLogger() *Logger

NewLogger function creates a new logger instance that defines the loggrus TextFormatter with [ForceColors:true]

func (*Logger) Debug

func (l *Logger) Debug(args ...interface{})

Debug

func (*Logger) Debugf

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

Debugf

func (*Logger) Debugln

func (l *Logger) Debugln(args ...interface{})

Debugln

func (*Logger) Error

func (l *Logger) Error(format string, args ...interface{})

Error

func (*Logger) Errorf

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

Errorf

func (*Logger) Errorln

func (l *Logger) Errorln(format string, args ...interface{})

Errorln

func (*Logger) Fatal

func (l *Logger) Fatal(format string, args ...interface{})

Fatal

func (*Logger) Fatalf

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

Fatalf

func (*Logger) Fatalln

func (l *Logger) Fatalln(format string, args ...interface{})

Fatalln

func (*Logger) Info

func (l *Logger) Info(args ...interface{})

Info

func (*Logger) Infof

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

Infof

func (*Logger) Infoln

func (l *Logger) Infoln(args ...interface{})

Infoln

func (*Logger) SetLogLevel

func (l *Logger) SetLogLevel(level LogLevel)

SetLogLevel

func (*Logger) Warn

func (l *Logger) Warn(format string, args ...interface{})

Warn

func (*Logger) Warnf

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

Warnf

func (*Logger) Warnln

func (l *Logger) Warnln(format string, args ...interface{})

Warnln

func (*Logger) WithField

func (l *Logger) WithField(key string, value interface{})

WithField

func (*Logger) WithFields

func (l *Logger) WithFields(fields logrus.Fields)

WithFields

Jump to

Keyboard shortcuts

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