logger

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AttractiveHandler

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

func NewAttractiveHandler

func NewAttractiveHandler(out io.Writer, opts AttractiveHandlerOptions) *AttractiveHandler

func (*AttractiveHandler) Enabled

func (h *AttractiveHandler) Enabled(ctx context.Context, level slog.Level) bool

func (*AttractiveHandler) Handle

func (h *AttractiveHandler) Handle(ctx context.Context, r slog.Record) error

func (*AttractiveHandler) WithAttrs

func (h *AttractiveHandler) WithAttrs(attrs []slog.Attr) slog.Handler

func (*AttractiveHandler) WithGroup

func (h *AttractiveHandler) WithGroup(name string) slog.Handler

type AttractiveHandlerOptions

type AttractiveHandlerOptions struct {
	SlogOpts      *slog.HandlerOptions
	TimeFormat    string
	UseAttractive bool
	UseFormat     bool
}

type Message

type Message struct {
	Time  string
	Level string
	Msg   string
	Atrs  string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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