lg

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2018 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

short for "log"

Index

Constants

View Source
const (
	DEBUG = LogLevel(1)
	INFO  = LogLevel(2)
	WARN  = LogLevel(3)
	ERROR = LogLevel(4)
	FATAL = LogLevel(5)
)

Variables

This section is empty.

Functions

func Logf

func Logf(logger Logger, cfgLevel LogLevel, msgLevel LogLevel, f string, args ...interface{})

Types

type AppLogFunc

type AppLogFunc func(lvl LogLevel, f string, args ...interface{})

type LogLevel

type LogLevel int

func ParseLogLevel

func ParseLogLevel(levelstr string, verbose bool) (LogLevel, error)

func (LogLevel) String

func (l LogLevel) String() string

type Logger

type Logger interface {
	Output(maxdepth int, s string) error
}

type NilLogger

type NilLogger struct{}

func (NilLogger) Output

func (l NilLogger) Output(maxdepth int, s string) error

Jump to

Keyboard shortcuts

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