log

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(msg string, args ...any)

Debug calls [Logger.Debug] on the current logger.

func DebugContext

func DebugContext(ctx context.Context, msg string, args ...any)

DebugContext calls [Logger.DebugContext] on the current logger.

func DebugEnabled added in v0.4.4

func DebugEnabled() bool

func Error

func Error(msg string, args ...any)

Error calls [Logger.Error] on the current logger.

func ErrorContext

func ErrorContext(ctx context.Context, msg string, args ...any)

ErrorContext calls [Logger.ErrorContext] on the current logger.

func Info

func Info(msg string, args ...any)

Info calls [Logger.Info] on the current logger.

func InfoContext

func InfoContext(ctx context.Context, msg string, args ...any)

InfoContext calls [Logger.InfoContext] on the current logger.

func Log

func Log(ctx context.Context, level slog.Level, msg string, args ...any)

Log calls [Logger.Log] on the current logger.

func LogAttrs

func LogAttrs(ctx context.Context, level slog.Level, msg string, attrs ...slog.Attr)

LogAttrs calls [Logger.LogAttrs] on the current logger.

func Logger

func Logger() *slog.Logger

func SetDefaultLoggerLevel

func SetDefaultLoggerLevel(logLevel string)

func SetLogger

func SetLogger(l *slog.Logger)

func Warn

func Warn(msg string, args ...any)

Warn calls [Logger.Warn] on the current logger.

func WarnContext

func WarnContext(ctx context.Context, msg string, args ...any)

WarnContext calls [Logger.WarnContext] on the current logger.

Types

This section is empty.

Jump to

Keyboard shortcuts

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