console

package
v0.34.0 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewProvider

func NewProvider(opts Options) interfaces.LoggerProvider

NewProvider constructs a console-backed logger provider that satisfies the CMS logging interfaces. Callers can override defaults via Options, otherwise logs are written to stdout with a minimum severity of DEBUG.

Types

type Level

type Level uint8

Level represents the severity attached to a log entry.

const (
	LevelTrace Level = iota
	LevelDebug
	LevelInfo
	LevelWarn
	LevelError
	LevelFatal
)

func (Level) String

func (l Level) String() string

String renders the severity label used in console output.

type Options

type Options struct {
	Writer   io.Writer
	TimeFunc func() time.Time
	MinLevel *Level
}

Options configures the console logger provider.

Jump to

Keyboard shortcuts

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