Documentation
¶
Index ¶
Constants ¶
View Source
const ( KB = 1 << (10 * iota) MB GB TB )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { Level Level OutputType OutputType LogFileRollingType RollingType LogFileOutputDir string LogFileName string LogFileMaxSize int64 // 字节 }
type Logger ¶
type Logger interface { SetLevel(level Level) SetPrefixes(prefix ...string) I(format string, v ...interface{}) D(format string, v ...interface{}) W(format string, v ...interface{}) E(format string, v ...interface{}) Close() }
var DefaultLogger Logger
type RollingType ¶
type RollingType int
const ( RollingNone = 0 RollingDaily RollingType = 1 << iota RollingSize )
Click to show internal directories.
Click to hide internal directories.