logger

package
v0.0.0-...-2e696e2 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2017 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LogLevel_Debug = "debug"
	LogLevel_Info  = "info"
	LogLevel_Warn  = "warn"
	LogLevel_Error = "error"
)

Variables

View Source
var (
	DefaultLogPath string
	EnabledLog     bool = true
)

Functions

func InitLog

func InitLog()

func NewXLog

func NewXLog() *xLog

create new xLog

func SetEnabledLog

func SetEnabledLog(isLog bool)

func SetLogPath

func SetLogPath(path string)

func SetLogger

func SetLogger(logger AppLog)

Types

type AppLog

type AppLog interface {
	SetLogPath(logPath string)
	SetEnabledLog(enabledLog bool)
	Debug(log string, logTarget string)
	Info(log string, logTarget string)
	Warn(log string, logTarget string)
	Error(log string, logTarget string)
	Log(log string, logTarget string, logLevel string)
}

func Logger

func Logger() AppLog

Jump to

Keyboard shortcuts

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