log

package
v0.0.0-...-924e1ad Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2014 License: MIT, MIT Imports: 1 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	AllLevels  = Level{/* contains filtered or unexported fields */}
	TraceLevel = Level{"[TRACE]", -127}
	DebugLevel = Level{"[DEBUG]", -64}
	InfoLevel  = Level{"[INFO]", 0}
	WarnLevel  = Level{"[WARN]", 64}
	ErrorLevel = Level{"[ERROR]", 127}
)

Functions

func Debug

func Debug(v ...interface{})

func Debugf

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

func Error

func Error(v ...interface{})

func Errorf

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

func Info

func Info(v ...interface{})

func Infof

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

func Log

func Log(level Level, v ...interface{})

func Logf

func Logf(level Level, format string, args ...interface{})

func Trace

func Trace(v ...interface{})

func Tracef

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

func Warn

func Warn(v ...interface{})

func Warnf

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

Types

type Level

type Level struct {
	Prefix string
	// contains filtered or unexported fields
}

func (Level) IsLoggable

func (level Level) IsLoggable(other Level) bool

type Logger

type Logger interface {
	Name() string
	Level() Level

	Log(level Level, v ...interface{})
	Logf(level Level, format string, args ...interface{})
}

func Get

func Get() Logger

Jump to

Keyboard shortcuts

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