logger

package
v1.0.45 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2020 License: MIT Imports: 4 Imported by: 3

Documentation

Index

Constants

View Source
const (
	NONE  = 0
	FATAL = 1
	ERROR = 2
	INFO  = 3
	DEBUG = 4
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Logger

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

func (*Logger) Close

func (l *Logger) Close()

func (*Logger) Debug

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

func (*Logger) Error

func (l *Logger) Error(v ...interface{})

func (*Logger) Fatal

func (l *Logger) Fatal(v ...interface{})

func (*Logger) Info

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

func (*Logger) Init

func (l *Logger) Init(lvl int, prefix string)

Init - Initialize loggind

func (*Logger) SetLevel

func (l *Logger) SetLevel(lvl int)

SetLevel - Configures the log level. Higher the number more verbose.

func (*Logger) SetLogFile

func (l *Logger) SetLogFile(logFile io.Writer, verbose bool)

SetLogFile - Writes log to the file. set verbose false disables log to os.Stderr

Jump to

Keyboard shortcuts

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