Documentation ¶
Index ¶
- func WithCallerSkip(i int) logger.Option
- func WithConfig(c zap.Config) logger.Option
- func WithEncoderConfig(c zapcore.EncoderConfig) logger.Option
- func WithFileWriter(fw FileWriter) logger.Option
- func WithJSONEncode() logger.Option
- func WithNamespace(namespace string) logger.Option
- func WithWriter(writer zapcore.WriteSyncer) logger.Option
- type FileWriter
- type ZapLog
- func (l *ZapLog) Error(err error) logger.Logger
- func (l *ZapLog) Fields(fields map[string]interface{}) logger.Logger
- func (l *ZapLog) GetLogger() *zap.Logger
- func (l *ZapLog) Init(opts ...logger.Option) error
- func (l *ZapLog) Log(level logger.Level, args ...interface{})
- func (l *ZapLog) Logf(level logger.Level, format string, args ...interface{})
- func (l *ZapLog) Options() logger.Options
- func (l *ZapLog) String() string
- func (l *ZapLog) Sync() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithCallerSkip ¶
func WithEncoderConfig ¶
func WithEncoderConfig(c zapcore.EncoderConfig) logger.Option
WithEncoderConfig pass zapcore.EncoderConfig to logger
func WithFileWriter ¶
func WithFileWriter(fw FileWriter) logger.Option
func WithJSONEncode ¶
func WithNamespace ¶
func WithWriter ¶
func WithWriter(writer zapcore.WriteSyncer) logger.Option
Types ¶
type FileWriter ¶
Click to show internal directories.
Click to hide internal directories.