logging

package
v0.0.0-...-155a76e Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(a ...any)

func Debugf

func Debugf(format string, a ...any)

func Error

func Error(a ...any)

func Errorf

func Errorf(format string, a ...any)

func Info

func Info(a ...any)

func Infof

func Infof(format string, a ...any)

func Log

func Log(level Level, a ...any)

func Logf

func Logf(level Level, format string, a ...any)

func SetConsoleFilter

func SetConsoleFilter(levels Level)

func SetFileFilter

func SetFileFilter(levels Level)

func SetUDPFilter

func SetUDPFilter(levels Level)

func Warn

func Warn(a ...any)

func Warnf

func Warnf(format string, a ...any)

Types

type Level

type Level uint8
const (
	LevelNone   Level = C.log_level_none
	LevelAll    Level = C.log_level_all
	LevelInfo   Level = C.log_level_info
	LevelWarn   Level = C.log_level_warning
	LevelError  Level = C.log_level_error
	LevelFatal  Level = C.log_level_fatal
	LevelDebug  Level = C.log_level_debug1
	LevelDebug1 Level = C.log_level_debug1
	LevelDebug2 Level = C.log_level_debug2
	LevelDebug3 Level = C.log_level_debug3
	LevelDebug4 Level = C.log_level_debug4
)

func (Level) String

func (l Level) String() string

type LogMessage

type LogMessage struct {
	Time     int64
	Host     string
	Process  string
	UnitName string
	Content  string
	Pid      int32
	Level    Level
}

type Logging

type Logging struct {
	Messages []LogMessage
}

func GetLogging

func GetLogging() Logging

Jump to

Keyboard shortcuts

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