Documentation ¶
Index ¶
- type GoLogger
- type GoTestingLogger
- func (g *GoTestingLogger) Crit(msg string, ctx ...interface{})
- func (g *GoTestingLogger) Debug(msg string, ctx ...interface{})
- func (g *GoTestingLogger) Error(msg string, ctx ...interface{})
- func (g *GoTestingLogger) Info(msg string, ctx ...interface{})
- func (g *GoTestingLogger) Warn(msg string, ctx ...interface{})
- type Logger
- type PgxLogAdapter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GoLogger ¶
type GoLogger struct {
// contains filtered or unexported fields
}
GoLogger wraps the builtin log.Logger into our own Logger
func NewGoLogger ¶
NewGoLogger returns a GoLogger wrapping the passed log.Logger
type GoTestingLogger ¶ added in v0.1.16
type GoTestingLogger struct {
// contains filtered or unexported fields
}
GoTestingLogger wraps the builtin log.Logger into our own Logger
func NewGoTestingLoggerr ¶ added in v0.1.16
func NewGoTestingLoggerr(t *testing.T) *GoTestingLogger
NewGoTestingLoggerr returns a GoTestingLogger wrapping the passed testing.T.Log()
func (*GoTestingLogger) Crit ¶ added in v0.1.16
func (g *GoTestingLogger) Crit(msg string, ctx ...interface{})
Crit implements Logger
func (*GoTestingLogger) Debug ¶ added in v0.1.16
func (g *GoTestingLogger) Debug(msg string, ctx ...interface{})
Debug implements Logger
func (*GoTestingLogger) Error ¶ added in v0.1.16
func (g *GoTestingLogger) Error(msg string, ctx ...interface{})
Error implements Logger
func (*GoTestingLogger) Info ¶ added in v0.1.16
func (g *GoTestingLogger) Info(msg string, ctx ...interface{})
Info implements Logger
func (*GoTestingLogger) Warn ¶ added in v0.1.16
func (g *GoTestingLogger) Warn(msg string, ctx ...interface{})
Warn implements Logger
type Logger ¶
type Logger interface { Debug(msg string, ctx ...interface{}) Info(msg string, ctx ...interface{}) Warn(msg string, ctx ...interface{}) Error(msg string, ctx ...interface{}) Crit(msg string, ctx ...interface{}) }
Logger provides a seemingly sane logging interface.
type PgxLogAdapter ¶
type PgxLogAdapter struct {
// contains filtered or unexported fields
}
PgxLogAdapter wraps anything that satisfies Logger into pgx.Logger
func NewPgxLogAdapter ¶
func NewPgxLogAdapter(l Logger) *PgxLogAdapter
NewPgxLogAdapter returns a PgxLogAdapter wrapping the passed Logger.
Click to show internal directories.
Click to hide internal directories.