logging

package
v0.40.1 Latest Latest
Warning

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

Go to latest
Published: May 31, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultMaxEntries = 10

Variables

This section is empty.

Functions

This section is empty.

Types

type Buffer

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

func NewBuffer

func NewBuffer(maxEntries int) *Buffer

func (*Buffer) MaxEntries

func (b *Buffer) MaxEntries() int

func (*Buffer) Subscribe

func (b *Buffer) Subscribe() <-chan Entry

func (*Buffer) Tail

func (b *Buffer) Tail(n int) []Entry

func (*Buffer) Write

func (b *Buffer) Write(p []byte) (int, error)

type Entry

type Entry struct {
	Text string
}

type Logger

type Logger interface {
	io.Writer
	MaxEntries() int
	Tail(n int) []Entry
	Subscribe() <-chan Entry
}

Jump to

Keyboard shortcuts

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