Documentation
¶
Index ¶
- Variables
- type FxZapLoggerDecorator
- type Logger
- type NopLogger
- func (n NopLogger) Debug(args ...interface{})
- func (n NopLogger) Debugf(template string, args ...interface{})
- func (n NopLogger) Error(args ...interface{})
- func (n NopLogger) Errorf(template string, args ...interface{})
- func (n NopLogger) GetFxLogger() fxevent.Logger
- func (n NopLogger) GetGormLogger() gormLogger.Interface
- func (n NopLogger) GetZapLogger() *zap.Logger
- func (n NopLogger) Info(args ...interface{})
- func (n NopLogger) Infof(template string, args ...interface{})
- func (n NopLogger) Warn(args ...interface{})
- func (n NopLogger) Warnf(template string, args ...interface{})
- func (n NopLogger) With(fields ...interface{}) Logger
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type FxZapLoggerDecorator ¶
FxZapLoggerDecorator is a Fx event logger decorator that logs events to Zap.
func NewFxZapLoggerDecorator ¶
func NewFxZapLoggerDecorator(zapLogger *zap.Logger) *FxZapLoggerDecorator
func (*FxZapLoggerDecorator) LogEvent ¶
func (l *FxZapLoggerDecorator) LogEvent(event fxevent.Event)
LogEvent logs the given event to the provided Zap logger.
type Logger ¶
type Logger interface { Debug(args ...interface{}) Debugf(template string, args ...interface{}) Info(args ...interface{}) Infof(template string, args ...interface{}) Warn(args ...interface{}) Warnf(template string, args ...interface{}) Error(args ...interface{}) Errorf(template string, args ...interface{}) With(args ...interface{}) Logger GetFxLogger() fxevent.Logger GetGormLogger() gormLogger.Interface GetZapLogger() *zap.Logger }
type NopLogger ¶
type NopLogger struct{}
func (NopLogger) GetFxLogger ¶
func (NopLogger) GetGormLogger ¶
func (n NopLogger) GetGormLogger() gormLogger.Interface
func (NopLogger) GetZapLogger ¶
Click to show internal directories.
Click to hide internal directories.