logger

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2022 License: Apache-2.0 Imports: 5 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// IsVerbose 是否调试
	IsVerbose = false

	// Outputs 输出
	Outputs = []io.Writer{os.Stderr}
)

Functions

func PrintArgs

func PrintArgs(w io.Writer, args ...string)

PrintArgs 输出字符串数组

func PrintReader

func PrintReader(r io.Reader)

PrintReader 输出Reader

func TimePrefix

func TimePrefix() string

func Verbosef

func Verbosef(format string, a ...interface{}) (n int, err error)

Verbosef 调试格式输出

func Verboseln

func Verboseln(a ...interface{}) (n int, err error)

Verboseln 调试输出一行

Types

type CmdVerbose

type CmdVerbose struct {
	Module string
}

CmdVerbose 调试

func New

func New(module, envVerbose string) *CmdVerbose

func (*CmdVerbose) Info

func (pv *CmdVerbose) Info(l string)

Info 提示

func (*CmdVerbose) Infof

func (pv *CmdVerbose) Infof(format string, a ...interface{})

Infof 提示, 格式输出

func (*CmdVerbose) Warn

func (pv *CmdVerbose) Warn(l string)

Warn 警告

func (*CmdVerbose) Warnf

func (pv *CmdVerbose) Warnf(format string, a ...interface{})

Warnf 警告, 格式输出

Jump to

Keyboard shortcuts

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