Documentation ¶
Index ¶
- func CyanColor(str interface{}) string
- func GreenColor(str interface{}) string
- func InitZap(opts ...OptionFunc)
- func Log(level zapcore.Level, message string, context string, scope string)
- func LogE(message string)
- func LogEf(format string, i ...interface{})
- func LogGreen(str string)
- func LogI(message string)
- func LogIf(format string, i ...interface{})
- func LogIfError(err error)
- func LogPanicIfError(err error)
- func LogRed(str string)
- func LogWithDefer(str string) (deferFunc func())
- func LogWithField(level zapcore.Level, fields map[string]interface{})
- func LogYellow(str string)
- func RedColor(str interface{}) string
- func YellowColor(str interface{}) string
- type Option
- type OptionFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LogPanicIfError ¶ added in v1.11.26
func LogPanicIfError(err error)
LogPanicIfError log if error not nil
func LogWithDefer ¶
func LogWithDefer(str string) (deferFunc func())
LogWithDefer return defer func for status
func LogWithField ¶ added in v1.9.3
LogWithField func
Types ¶
type OptionFunc ¶ added in v1.9.3
type OptionFunc func(*Option)
OptionFunc func
func OptionAddWriter ¶ added in v1.9.3
func OptionAddWriter(w io.Writer) OptionFunc
OptionAddWriter option func
func OptionSetWriter ¶ added in v1.12.2
func OptionSetWriter(w ...io.Writer) OptionFunc
OptionSetWriter option func, overide all log writer
Click to show internal directories.
Click to hide internal directories.