Documentation ¶
Overview ¶
Package loglg adapts stdlib's log pkg for use with the lg interface.
Index ¶
- type Log
- func (l *Log) Debug(a ...interface{})
- func (l *Log) Debugf(format string, a ...interface{})
- func (l *Log) Error(a ...interface{})
- func (l *Log) Errorf(format string, a ...interface{})
- func (l *Log) Warn(a ...interface{})
- func (l *Log) WarnIfCloseError(c io.Closer)
- func (l *Log) WarnIfError(err error)
- func (l *Log) WarnIfFuncError(fn func() error)
- func (l *Log) Warnf(format string, a ...interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Log ¶
type Log struct {
// contains filtered or unexported fields
}
Log implements lg.Log.
func New ¶
func New() *Log
New returns a Log instance that writes to os.Stdout, reporting caller and log level.
func NewWith ¶
NewWith returns a Log that writes to w. The timestamp, level and caller params determine if those fields are reported.
func (*Log) WarnIfCloseError ¶
func (*Log) WarnIfError ¶
func (*Log) WarnIfFuncError ¶
Click to show internal directories.
Click to hide internal directories.