log

package
v0.0.0-...-37de6bf Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2020 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LEVEL_FATAL = iota
	LEVEL_ERROR
	LEVEL_WARNING
	LEVEL_INFO
	LEVEL_DEBUG
)

Variables

This section is empty.

Functions

This section is empty.

Types

type LogNode

type LogNode struct {
	Level     int
	Timestamp time.Time
	Message   string
}

func (*LogNode) ToString

func (n *LogNode) ToString() string

type Logger

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

func GetLogger

func GetLogger(baseDir string, id string, level int) *Logger

func (*Logger) Close

func (l *Logger) Close()

func (*Logger) Debug

func (l *Logger) Debug(s string)

func (*Logger) Error

func (l *Logger) Error(s string)

func (*Logger) Fatal

func (l *Logger) Fatal(s string)

func (*Logger) GetLevel

func (l *Logger) GetLevel() int

func (*Logger) Info

func (l *Logger) Info(s string)

func (*Logger) SetLevel

func (l *Logger) SetLevel(n int)

func (*Logger) Warning

func (l *Logger) Warning(s string)

Jump to

Keyboard shortcuts

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