log

package
v1.36.0 Latest Latest
Warning

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

Go to latest
Published: Feb 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 Close

func Close() error

Close closes the debug log file if open.

func Printf

func Printf(format string, args ...any)

Printf writes a formatted debug message via the standard logger.

func Println

func Println(v ...any)

Println writes a debug message via the standard logger.

func SetFile

func SetFile(path string) error

SetFile sets the debug log file path. Creates the file if it doesn't exist. If path is empty, discards all buffered logs and future logs.

Types

type DebugLogger

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

DebugLogger handles debug logging to file and/or buffering. It implements io.Writer to be compatible with standard log.Logger.

func (*DebugLogger) Write

func (l *DebugLogger) Write(p []byte) (n int, err error)

Write implements io.Writer. It writes to the file if set, otherwise appends to the buffer.

Jump to

Keyboard shortcuts

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