Documentation ¶
Index ¶
- func ErrWrapper(err Err) error
- type Err
- type Level
- type Log
- type OptionFunc
- func WithCaller(caller bool, callerSkip int) OptionFunc
- func WithConsole(console bool) OptionFunc
- func WithFileName(fileName string) OptionFunc
- func WithLevel(level string) OptionFunc
- func WithMaxAge(maxAge int) OptionFunc
- func WithMaxBackups(maxBackups int) OptionFunc
- func WithMaxSize(maxSize int) OptionFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ErrWrapper ¶ added in v0.0.34
Types ¶
type Log ¶ added in v0.0.52
type Log interface { Debugf(template string, args ...any) Debugw(msg string, keysAndValues ...interface{}) Infof(template string, args ...any) Infow(msg string, keysAndValues ...interface{}) Warnf(template string, args ...any) Warnw(msg string, keysAndValues ...interface{}) Errorf(template string, args ...any) Errorw(msg string, keysAndValues ...interface{}) }
func NewLogger ¶
func NewLogger(opts ...OptionFunc) (Log, error)
type OptionFunc ¶ added in v0.0.46
type OptionFunc func(*config)
func WithCaller ¶ added in v0.0.44
func WithCaller(caller bool, callerSkip int) OptionFunc
func WithConsole ¶
func WithConsole(console bool) OptionFunc
func WithFileName ¶
func WithFileName(fileName string) OptionFunc
func WithLevel ¶
func WithLevel(level string) OptionFunc
func WithMaxAge ¶
func WithMaxAge(maxAge int) OptionFunc
func WithMaxBackups ¶
func WithMaxBackups(maxBackups int) OptionFunc
func WithMaxSize ¶
func WithMaxSize(maxSize int) OptionFunc
Click to show internal directories.
Click to hide internal directories.