logrus

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

func NewLogger

func NewLogger(opts ...Options) kiko_logger.Logger

Types

type KLLogger

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

func (*KLLogger) AddHooks

func (l *KLLogger) AddHooks(hooks ...logrus.Hook)

func (*KLLogger) Debug

func (l *KLLogger) Debug(args ...interface{})

func (*KLLogger) Debugf

func (l *KLLogger) Debugf(template string, args ...interface{})

func (*KLLogger) Error

func (l *KLLogger) Error(args ...interface{})

func (*KLLogger) Errorf

func (l *KLLogger) Errorf(template string, args ...interface{})

func (*KLLogger) Fatal

func (l *KLLogger) Fatal(args ...interface{})

func (*KLLogger) Fatalf

func (l *KLLogger) Fatalf(template string, args ...interface{})

func (*KLLogger) Info

func (l *KLLogger) Info(args ...interface{})

func (*KLLogger) Infof

func (l *KLLogger) Infof(template string, args ...interface{})

func (*KLLogger) Option

func (l *KLLogger) Option() *Option

func (*KLLogger) SetLevel

func (l *KLLogger) SetLevel(lv kiko_logger.Level)

func (*KLLogger) StdLog

func (l *KLLogger) StdLog() *log.Logger

func (*KLLogger) Sync

func (l *KLLogger) Sync() error

func (*KLLogger) Warn

func (l *KLLogger) Warn(args ...interface{})

func (*KLLogger) Warnf

func (l *KLLogger) Warnf(template string, args ...interface{})

func (*KLLogger) WithCallDepth

func (l *KLLogger) WithCallDepth(callDepth int) kiko_logger.Logger

func (*KLLogger) WithContext

func (l *KLLogger) WithContext(ctx context.Context) kiko_logger.Logger

func (*KLLogger) WithError

func (l *KLLogger) WithError(err error) kiko_logger.Logger

func (*KLLogger) WithFields

func (l *KLLogger) WithFields(fields map[string]interface{}) kiko_logger.Logger

type Level

type Level int8

type Option

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

type Options

type Options func(o *Option)

func WithFileName

func WithFileName(fileName string) Options

func WithFormatter

func WithFormatter(formatter logrus.Formatter) Options

func WithHook

func WithHook(hook ...logrus.Hook) Options

func WithLevel

func WithLevel(level Level) Options

func WithOutPut

func WithOutPut(output ...io.Writer) Options

func WithRotateLog

func WithRotateLog(rotateOpts ...rotatelogs.Option) Options

WithRotateLog 处理数据

func WithStdOut

func WithStdOut(stdout bool) Options

func WithTimeFormat

func WithTimeFormat(timeStr string) Options

Jump to

Keyboard shortcuts

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