log

package
v1.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 30, 2025 License: BSD-2-Clause Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewContextHandler

func NewContextHandler(wrapped slog.Handler) slog.Handler

func WithContextAttrs

func WithContextAttrs(ctx context.Context, attrs ...slog.Attr) context.Context

Types

type ContextHandler

type ContextHandler struct {
	// contains filtered or unexported fields
}

func (ContextHandler) Enabled

func (c ContextHandler) Enabled(ctx context.Context, level slog.Level) bool

func (ContextHandler) Handle

func (c ContextHandler) Handle(ctx context.Context, record slog.Record) error

func (ContextHandler) WithAttrs

func (c ContextHandler) WithAttrs(attrs []slog.Attr) slog.Handler

func (ContextHandler) WithGroup

func (c ContextHandler) WithGroup(name string) slog.Handler

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL