Documentation
¶
Index ¶
- func AttrsFromMap(m map[string]any) []any
- type ContextExtractor
- type ContextExtractorFunction
- type ContextHandler
- func (contextHandler *ContextHandler) Enabled(ctx context.Context, level slog.Level) bool
- func (contextHandler *ContextHandler) Handle(ctx context.Context, record slog.Record) error
- func (contextHandler *ContextHandler) WithAttrs(attrs []slog.Attr) slog.Handler
- func (contextHandler *ContextHandler) WithGroup(name string) slog.Handler
- type ErrorContextExtractor
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AttrsFromMap ¶
Types ¶
type ContextExtractor ¶
type ContextHandler ¶
type ContextHandler struct {
Next slog.Handler
Extractors []ContextExtractor
}
type ErrorContextExtractor ¶
type ErrorContextExtractor struct {
SkipCause bool
SkipInput bool
SkipStackTrace bool
SkipOutput bool
ContextExtractors []ContextExtractor
}
func (*ErrorContextExtractor) MakeErrorAttrs ¶
func (extractor *ErrorContextExtractor) MakeErrorAttrs(err error) []any
Click to show internal directories.
Click to hide internal directories.