kafka

package
v0.1.12 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Adapter

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

Adapter is a component that print log message on terminal.

func NewAdapter

func NewAdapter() *Adapter

NewAdapter creates a new adapter for terminal.

func (*Adapter) GetBucket

func (o *Adapter) GetBucket() *base.Bucket[*base.Item]

GetBucket return logger items bucket.

func (*Adapter) GetFormatter

func (o *Adapter) GetFormatter() base.LoggerFormatter

GetFormatter returns the logger formatter.

func (*Adapter) Log

func (o *Adapter) Log(item *base.Item)

Log add logger item into bucket.

func (*Adapter) SetFormatter

func (o *Adapter) SetFormatter(formatter base.LoggerFormatter)

SetFormatter set the logger formatter.

type Formatter

type Formatter struct{}

Formatter is a component that convert log item to string.

func (*Formatter) Format

func (o *Formatter) Format(_ *base.Item) (body []byte)

Format log item as string.

Jump to

Keyboard shortcuts

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