netlog

package
v0.9.8 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NetLogCallback

type NetLogCallback func(NetLogMessage)

type NetLogMessage

type NetLogMessage struct {
	Level   zerolog.Level
	Message []byte
	Address string
}

type NetLogReceiver

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

NetLogReceiver receives log messages over UDP.

func NewLogReceiver

func NewLogReceiver(cb NetLogCallback) (*NetLogReceiver, error)

NewLogReceiver constructs a new UDP log receiver

type NetLogger

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

NetLogger send log messages over UDP.

func NewLogger

func NewLogger() (*NetLogger, error)

NewLogger constructs a new UDP logger

func (*NetLogger) Write

func (l *NetLogger) Write(p []byte) (int, error)

Write a std message

func (*NetLogger) WriteLevel

func (l *NetLogger) WriteLevel(level zerolog.Level, p []byte) (n int, err error)

Write a message with given level

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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