z1log

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: May 21, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DPanic

func DPanic(args ...interface{})

DPanic DPanic("msg",v)

func DPanicf

func DPanicf(template string, args ...interface{})

DPanicf DPanicf("msg %v",v)

func Debug

func Debug(args ...interface{})

Debug Debug("msg",v)

func Debugf

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

Debugf Debugf("msg %v",v)

func Error

func Error(args ...interface{})

Error Error("msg",v)

func Errorf

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

Errorf Errorf("msg %v",v)

func Fatal

func Fatal(args ...interface{})

Fatal Fatal("msg",v)

func Fatalf

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

Fatalf Fatalf("msg %v",v)

func Info

func Info(args ...interface{})

Info Info("msg",v)

func Infof

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

Infof Infof("msg %v",v)

func Panic

func Panic(args ...interface{})

Panic Panic("msg",v)

func Panicf

func Panicf(template string, args ...interface{})

Panicf Panicf("msg %v",v)

func SetCallerSkip

func SetCallerSkip(skip int)

SetCallerSkip default 1

func SetCompress

func SetCompress(compress bool)

SetCompress default false

func SetJsonFormat

func SetJsonFormat(jsonFormat bool)

SetJsonFormat default false

func SetLogPath

func SetLogPath(logPath string)

SetLogPath default ./logs

func SetMaxAge

func SetMaxAge(maxAge int)

SetMaxAge 1 as 1 day

func SetMaxBackups

func SetMaxBackups(maxBackups int)

SetMaxBackups The default is to retain all old log files

func SetMaxSize

func SetMaxSize(maxSize int)

SetMaxSize default 100M

func SetOutput added in v0.1.3

func SetOutput(output string)

SetOutput console/file/both,default both

func SetShowLine

func SetShowLine(showLine bool)

SetShowLine default true

func Warn

func Warn(args ...interface{})

Warn Warn("msg",v)

func Warnf

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

Warnf Warnf("msg %v",v)

Types

type Z1logger

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

Z1logger define

func NewZ1logger

func NewZ1logger() *Z1logger

NewZ1logger new

Jump to

Keyboard shortcuts

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