log

package
v0.0.0-...-5c0bb04 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Debug  func(string, ...interface{})
	Info   func(string, ...interface{})
	Warn   func(string, ...interface{})
	Error  func(string, ...interface{})
	DPanic func(string, ...interface{})
	Panic  func(string, ...interface{})
	Fatal  func(string, ...interface{})
)

print func

Functions

func Close

func Close()

Close log sync and remove instance

func Init

func Init(appName, logPath string, debug bool)

Init log instance

func Output

func Output() io.Writer

Output return a log io.Writer

func ShowLine

func ShowLine(enable bool) *zap.SugaredLogger

ShowLine Line number display switch

Types

type Printer

type Printer interface {
	Debugf(string, ...interface{})
	Infof(string, ...interface{})
	Warnf(string, ...interface{})
	Errorf(string, ...interface{})
	DPanicf(string, ...interface{})
	Panicf(string, ...interface{})
	Fatalf(string, ...interface{})
}

Printer print func interface list

Jump to

Keyboard shortcuts

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