logger

package
v2.5.1 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package logger Simple log output

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(v ...interface{})

Debug level

func Debugf

func Debugf(format string, v ...interface{})

Debugf level fmt

func Enable added in v2.3.0

func Enable() bool

Enable return log Enable

func Error

func Error(v ...interface{})

Error level

func Errorf

func Errorf(format string, v ...interface{})

Errorf level fmt

func Fatal

func Fatal(v ...interface{})

Fatal level

func Fatalf

func Fatalf(format string, v ...interface{})

Fatalf level fmt

func Info

func Info(v ...interface{})

Info level

func Infof

func Infof(format string, v ...interface{})

Infof level fmt

func SetEnable

func SetEnable(enable bool)

SetEnable enable log, default true

func SetLevel

func SetLevel(l Level)

SetLevel set log level

func SetLogFile added in v2.4.0

func SetLogFile(filePath string)

SetLogFile set log file full path

Types

type Level added in v2.4.0

type Level int8
const (
	LError Level = iota
	LInfo
	LDebug
)

type Logger added in v2.4.0

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

Logger logger conifg

Jump to

Keyboard shortcuts

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