logger

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultLogLevel = "info"

Variables

This section is empty.

Functions

func New

func New(opts ...Option) *zerolog.Logger

New creates a new logger instance

func NewConsoleLogger

func NewConsoleLogger() *zerolog.Logger

Types

type Config

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

Config holds logger configuration

type DecodedTransactionLogWrapper

type DecodedTransactionLogWrapper struct {
	seth.DecodedTransactionLog
}

func (DecodedTransactionLogWrapper) MarshalZerologObject

func (dtw DecodedTransactionLogWrapper) MarshalZerologObject(e *zerolog.Event)

type EventDataWrapper

type EventDataWrapper struct {
	EventData map[string]interface{}
}

func (EventDataWrapper) MarshalZerologObject

func (w EventDataWrapper) MarshalZerologObject(e *zerolog.Event)

type Option

type Option interface {
	// contains filtered or unexported methods
}

Option configures the logger

func WithConsoleWriter

func WithConsoleWriter(isDev bool) Option

WithConsoleWriter uses the console for pretty printer

func WithLevel

func WithLevel(level string) Option

WithLevel sets the logger level

func WithOutput

func WithOutput(output io.Writer) Option

WithOutput sets the output writer

Jump to

Keyboard shortcuts

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