log

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2015 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FacilityRing    Facility = "ringbuf"
	FacilityAgent            = "agent"
	FacilityDefault          = "ringio"
	FacilityStdout           = "stdout"
	FacilityStderr           = "stderr"
	FacilityPipe             = "pipe"
)

Variables

This section is empty.

Functions

func AddWriter

func AddWriter(w io.Writer)

func Cancel

func Cancel()

func Debug

func Debug(facility Facility, message ...interface{})

func Error

func Error(facility Facility, message ...interface{})

func Fatal

func Fatal(facility Facility, message ...interface{})

func Info

func Info(facility Facility, message ...interface{})

func Run

func Run(minLevel Level) bool

func Warn

func Warn(facility Facility, message ...interface{})

Types

type Facility

type Facility string

type Level

type Level int
const (
	LevelDebug Level = iota
	LevelInfo
	LevelWarn
	LevelError
	LevelFail
	LevelCancel
)

func LevelFromString

func LevelFromString(s string) (Level, error)

func (Level) String

func (l Level) String() string

type Logger

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

type Message

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

type NewlineWriter

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

func NewNewlineWriter

func NewNewlineWriter(w io.Writer) *NewlineWriter

func (*NewlineWriter) Write

func (nw *NewlineWriter) Write(b []byte) (int, error)

type NullWriter

type NullWriter struct{}

func (*NullWriter) Write

func (n *NullWriter) Write(b []byte) (int, error)

Jump to

Keyboard shortcuts

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