xlog

package
v0.37.7 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewContext

func NewContext(ctx context.Context, xl *Logger) context.Context

Types

type Logger

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

Logger is not thread safety for operations on prefix

func FromContext

func FromContext(ctx context.Context) (xl *Logger, ok bool)

func FromContextSafe

func FromContextSafe(ctx context.Context) *Logger

func New

func New() *Logger

func (*Logger) AppendPrefix

func (l *Logger) AppendPrefix(prefix string) *Logger

func (*Logger) Debug

func (l *Logger) Debug(format string, v ...interface{})

func (*Logger) Error

func (l *Logger) Error(format string, v ...interface{})

func (*Logger) Info

func (l *Logger) Info(format string, v ...interface{})

func (*Logger) ResetPrefixes

func (l *Logger) ResetPrefixes() (old []string)

func (*Logger) Spawn

func (l *Logger) Spawn() *Logger

func (*Logger) Trace

func (l *Logger) Trace(format string, v ...interface{})

func (*Logger) Warn

func (l *Logger) Warn(format string, v ...interface{})

Jump to

Keyboard shortcuts

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