rlog

package module
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2022 License: MIT Imports: 8 Imported by: 0

README

rlog

a rich and easy-to-use log based on logrus

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(args ...interface{})

func Debugf

func Debugf(format string, args ...interface{})

func Error

func Error(args ...interface{})

func Errorf

func Errorf(format string, args ...interface{})

func Info

func Info(args ...interface{})

func Infof

func Infof(format string, args ...interface{})

func Use

func Use(writers ...writer.Writer) error

Use 注册writer

func Warn

func Warn(args ...interface{})

func Warnf

func Warnf(format string, args ...interface{})

Types

type Logger

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

func (*Logger) Debug

func (log *Logger) Debug(args ...interface{})

func (*Logger) Debugf

func (log *Logger) Debugf(format string, args ...interface{})

func (*Logger) Error

func (log *Logger) Error(args ...interface{})

func (*Logger) Errorf

func (log *Logger) Errorf(format string, args ...interface{})

func (*Logger) Info

func (log *Logger) Info(args ...interface{})

func (*Logger) Infof

func (log *Logger) Infof(format string, args ...interface{})

func (*Logger) Warn

func (log *Logger) Warn(args ...interface{})

func (*Logger) Warnf

func (log *Logger) Warnf(format string, args ...interface{})

type RHook

type RHook struct {
	Formatter logrus.Formatter
	// contains filtered or unexported fields
}

RHook 实现logrus Hook接口

func (*RHook) Fire

func (hook *RHook) Fire(entry *logrus.Entry) (err error)

func (*RHook) Levels

func (hook *RHook) Levels() []logrus.Level

Directories

Path Synopsis
example

Jump to

Keyboard shortcuts

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