Documentation ¶
Index ¶
- Variables
- func Args(mess string, args ...interface{})
- func Debug(i ...interface{})
- func Debugf(format string, args ...interface{})
- func Error(i ...interface{})
- func Errorf(format string, args ...interface{})
- func Fatal(i ...interface{})
- func Fatalf(format string, args ...interface{})
- func Info(i ...interface{})
- func Infof(format string, args ...interface{})
- func LoggerHandler(next gin.HandlerFunc) gin.HandlerFunc
- func Panic(i ...interface{})
- func Panicf(format string, args ...interface{})
- func Print(i ...interface{})
- func Printf(format string, i ...interface{})
- func Warn(i ...interface{})
- func Warnf(format string, args ...interface{})
- type MyLogger
- func (l *MyLogger) Debug(i ...interface{})
- func (l *MyLogger) Debugf(format string, args ...interface{})
- func (l *MyLogger) Debugj(j log.JSON)
- func (l *MyLogger) Error(i ...interface{})
- func (l *MyLogger) Errorf(format string, args ...interface{})
- func (l *MyLogger) Errorj(j log.JSON)
- func (l *MyLogger) Fatal(i ...interface{})
- func (l *MyLogger) Fatalf(format string, args ...interface{})
- func (l *MyLogger) Fatalj(j log.JSON)
- func (l *MyLogger) Formatter() logrus.Formatter
- func (l *MyLogger) Info(i ...interface{})
- func (l *MyLogger) Infof(format string, args ...interface{})
- func (l *MyLogger) Infoj(j log.JSON)
- func (l *MyLogger) Level() log.Lvl
- func (l *MyLogger) Output() io.Writer
- func (l *MyLogger) Panic(i ...interface{})
- func (l *MyLogger) Panicf(format string, args ...interface{})
- func (l *MyLogger) Panicj(j log.JSON)
- func (l *MyLogger) Prefix() string
- func (l *MyLogger) Print(i ...interface{})
- func (l *MyLogger) Printf(format string, args ...interface{})
- func (l *MyLogger) Printj(j log.JSON)
- func (l *MyLogger) SetFormatter(formatter logrus.Formatter)
- func (l *MyLogger) SetHeader(h string)
- func (l *MyLogger) SetLevel(v log.Lvl)
- func (l *MyLogger) SetOutput(w io.Writer)
- func (l *MyLogger) SetPrefix(p string)
- func (l *MyLogger) Warn(i ...interface{})
- func (l *MyLogger) Warnf(format string, args ...interface{})
- func (l *MyLogger) Warnj(j log.JSON)
Constants ¶
This section is empty.
Variables ¶
View Source
var Log *logrus.Logger
Log global
Functions ¶
func Debugf ¶
func Debugf(format string, args ...interface{})
Debugf output format message of debug level
func Errorf ¶
func Errorf(format string, args ...interface{})
Errorf output format message of error level
func Fatalf ¶
func Fatalf(format string, args ...interface{})
Fatalf output format message of fatal level
func Infof ¶
func Infof(format string, args ...interface{})
Infof output format message of info level
func LoggerHandler ¶
func LoggerHandler(next gin.HandlerFunc) gin.HandlerFunc
func Panicf ¶
func Panicf(format string, args ...interface{})
Panicf output format message of panic level
Types ¶
type MyLogger ¶
MyLogger extend logrus.MyLogger
func Logger ¶
func Logger() *MyLogger
Logger returns singletonLogger NOTE: Must run InitLogger() before
func (*MyLogger) Debug ¶
func (l *MyLogger) Debug(i ...interface{})
Debug output message of debug level
func (*MyLogger) Error ¶
func (l *MyLogger) Error(i ...interface{})
Error output message of error level
func (*MyLogger) Fatal ¶
func (l *MyLogger) Fatal(i ...interface{})
Fatal output message of fatal level
func (*MyLogger) Panic ¶
func (l *MyLogger) Panic(i ...interface{})
Panic output message of panic level
func (*MyLogger) Print ¶
func (l *MyLogger) Print(i ...interface{})
Print output message of print level
func (*MyLogger) SetFormatter ¶
SetFormatter logger formatter Only support logrus formatter
Click to show internal directories.
Click to hide internal directories.