Documentation ¶
Index ¶
- Variables
- func Critical(a ...interface{})
- func Criticalf(format string, a ...interface{})
- func Criticalln(a ...interface{})
- func Debug(a ...interface{})
- func Debugf(format string, a ...interface{})
- func Debugln(a ...interface{})
- func Error(a ...interface{})
- func Errorf(format string, a ...interface{})
- func Errorln(a ...interface{})
- func Info(a ...interface{})
- func Infof(format string, a ...interface{})
- func Infoln(a ...interface{})
- func IsDebug() bool
- func Panic(a ...interface{})
- func Panicf(format string, a ...interface{})
- func Panicln(a ...interface{})
- func SetSeverity(severity Severity)
- func Warning(a ...interface{})
- func Warningf(format string, a ...interface{})
- func Warningln(a ...interface{})
- type Logger
- func (l *Logger) Critical(a ...interface{})
- func (l *Logger) Criticalf(format string, a ...interface{})
- func (l *Logger) Criticalln(a ...interface{})
- func (l *Logger) Debug(a ...interface{})
- func (l *Logger) Debugf(format string, a ...interface{})
- func (l *Logger) Debugln(a ...interface{})
- func (l *Logger) Error(a ...interface{})
- func (l *Logger) Errorf(format string, a ...interface{})
- func (l *Logger) Errorln(a ...interface{})
- func (l *Logger) Info(a ...interface{})
- func (l *Logger) Infof(format string, a ...interface{})
- func (l *Logger) Infoln(a ...interface{})
- func (l *Logger) Panic(a ...interface{})
- func (l *Logger) Panicf(format string, a ...interface{})
- func (l *Logger) Panicln(a ...interface{})
- func (l *Logger) Print(a ...interface{})
- func (l *Logger) Printf(format string, a ...interface{})
- func (l *Logger) Println(a ...interface{})
- func (l *Logger) Warning(a ...interface{})
- func (l *Logger) Warningf(format string, a ...interface{})
- func (l *Logger) Warningln(a ...interface{})
- type MsgCountWatcher
- type Severity
Constants ¶
This section is empty.
Variables ¶
var GlobalMsgCountWatcher = newMsgCountWatcher(resetEvery)
GlobalMsgCountWatcher is an initiated instance of MsgCountWatcher. It resets message counter for every registered logger every 1 seconds.
var (
Prefix = "goplugin"
)
Functions ¶
func Criticalf ¶
func Criticalf(format string, a ...interface{})
Criticalf logs a message with the Critical severity using the same syntax and options as fmt.Printf
func Criticalln ¶ added in v0.23.0
func Criticalln(a ...interface{})
Criticalln logs a message with the Critical severity
func Debugf ¶
func Debugf(format string, a ...interface{})
Debugf logs a message with the Debug severity using the same syntax and options as fmt.Printf
func Debugln ¶ added in v0.23.0
func Debugln(a ...interface{})
Debugln logs a message with the Debug severity
func Errorf ¶
func Errorf(format string, a ...interface{})
Errorf logs a message with the Error severity using the same syntax and options as fmt.Printf
func Errorln ¶ added in v0.23.0
func Errorln(a ...interface{})
Errorln logs a message with the Error severity
func Infof ¶
func Infof(format string, a ...interface{})
Infof logs a message with the Info severity using the same syntax and options as fmt.Printf
func Infoln ¶ added in v0.23.0
func Infoln(a ...interface{})
Infoln logs a message with the Info severity
func Panic ¶
func Panic(a ...interface{})
Panic logs a message with the Critical severity then panic
func Panicf ¶
func Panicf(format string, a ...interface{})
Panicf logs a message with the Critical severity using the same syntax and options as fmt.Printf then panic
func Panicln ¶ added in v0.23.0
func Panicln(a ...interface{})
Panicln logs a message with the Critical severity then panic
Types ¶
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
Logger represents a logger object
func NewLimited ¶
NewLimited creates a new limited logger
func (*Logger) Critical ¶
func (l *Logger) Critical(a ...interface{})
Critical logs a message with the Critical severity
func (*Logger) Criticalf ¶
Criticalf logs a message with the Critical severity using the same syntax and options as fmt.Printf
func (*Logger) Criticalln ¶ added in v0.23.0
func (l *Logger) Criticalln(a ...interface{})
Criticalln logs a message with the Critical severity
func (*Logger) Debug ¶
func (l *Logger) Debug(a ...interface{})
Debug logs a message with the Debug severity
func (*Logger) Debugf ¶
Debugf logs a message with the Debug severity using the same syntax and options as fmt.Printf
func (*Logger) Debugln ¶ added in v0.23.0
func (l *Logger) Debugln(a ...interface{})
Debugln logs a message with the Debug severity
func (*Logger) Error ¶
func (l *Logger) Error(a ...interface{})
Error logs a message with the Error severity
func (*Logger) Errorf ¶
Errorf logs a message with the Error severity using the same syntax and options as fmt.Printf
func (*Logger) Errorln ¶ added in v0.23.0
func (l *Logger) Errorln(a ...interface{})
Errorln logs a message with the Error severity
func (*Logger) Info ¶
func (l *Logger) Info(a ...interface{})
Info logs a message with the Info severity
func (*Logger) Infof ¶
Infof logs a message with the Info severity using the same syntax and options as fmt.Printf
func (*Logger) Infoln ¶ added in v0.23.0
func (l *Logger) Infoln(a ...interface{})
Infoln logs a message with the Info severity
func (*Logger) Panic ¶
func (l *Logger) Panic(a ...interface{})
Panic logs a message with the Critical severity then panic
func (*Logger) Panicf ¶
Panicf logs a message with the Critical severity using the same syntax and options as fmt.Printf then panic
func (*Logger) Panicln ¶ added in v0.23.0
func (l *Logger) Panicln(a ...interface{})
Panicln logs a message with the Critical severity then panic
func (*Logger) Print ¶ added in v0.23.0
func (l *Logger) Print(a ...interface{})
Print logs a message with the Info severity (same as Info)
func (*Logger) Printf ¶ added in v0.23.0
Printf logs a message with the Info severity using the same syntax and options as fmt.Printf
func (*Logger) Println ¶ added in v0.23.0
func (l *Logger) Println(a ...interface{})
Println logs a message with the Info severity (same as Infoln)
func (*Logger) Warning ¶
func (l *Logger) Warning(a ...interface{})
Warning logs a message with the Warning severity
type MsgCountWatcher ¶
type MsgCountWatcher struct {
// contains filtered or unexported fields
}
MsgCountWatcher MsgCountWatcher
func (*MsgCountWatcher) Register ¶
func (m *MsgCountWatcher) Register(logger *Logger)
Register adds logger to the collection.
func (*MsgCountWatcher) Unregister ¶
func (m *MsgCountWatcher) Unregister(logger *Logger)
Unregister removes logger from the collection.
type Severity ¶
type Severity int
Severity is a logging severity level
func (Severity) ShortString ¶
ShortString returns human-readable short string