Documentation ¶
Index ¶
- type Level
- type Logger
- func (l *Logger) Debug(args ...any)
- func (l *Logger) Debugf(format string, args ...any)
- func (l *Logger) Error(args ...any)
- func (l *Logger) Errorf(format string, args ...any)
- func (l *Logger) Fatal(args ...any)
- func (l *Logger) Fatalf(format string, args ...any)
- func (l *Logger) Info(args ...any)
- func (l *Logger) Infof(format string, args ...any)
- func (l *Logger) Warn(args ...any)
- func (l *Logger) Warnf(format string, args ...any)
- type Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Level ¶
type Level int32
Level defines the log severity levels.
Enumeration of log levels from least to most severe.
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
Logger represents the logging structure with configurable options.
func NewLogger ¶
NewLogger creates a new :ogger instance with the provided options. If no options are provided, default values are used.
func (*Logger) Fatalf ¶
Fatalf logs a formatted fatal error message and then terminates the program.
type Option ¶
type Option func(options *options) error
func WithWriter ¶
WithWriter sets the writer that will be used by the logger.
Click to show internal directories.
Click to hide internal directories.