Versions in this module Expand all Collapse all v0 v0.1.5 Jun 30, 2022 Changes in this version type Logger + func (l *Logger) Init() *errs.Err v0.1.4 Jun 20, 2022 v0.1.3 Jun 19, 2022 Changes in this version + var ConsTpls = map[LogLevel]string + var FileTpls = map[LogLevel]string + var LevelByName = map[string]LogLevel + var LevelNames = map[LogLevel]string + var LogTimeFmt = "" + type Config struct + ConsBufSize int + DSN string + File string + FileBufSize int + LevelCons LogLevel + LevelFile LogLevel + LevelStore LogLevel + StoreBufSize int + type LogLevel int + const LogDebug + const LogError + const LogFatal + const LogInfo + const LogNotify + const LogWarning + func GetLevelByName(name string) (lvl LogLevel, err *errs.Err) + type LogRec struct + Data datatypes.JSONMap + Level string + Msg string + SrcFile string + SrcFunc string + Time time.Time + type Logger struct + ConsTpls map[LogLevel]string + Dbg bool + FileTpls map[LogLevel]string + Silent bool + TimeFMT string + func New(cfg *Config) (log *Logger, err *errs.Err) + func (l *Logger) Debug(msg string, data ...map[string]interface{}) + func (l *Logger) Error(msg string, data ...map[string]interface{}) + func (l *Logger) Fatal(msg string, data ...map[string]interface{}) + func (l *Logger) Info(msg string, data ...map[string]interface{}) + func (l *Logger) Notify(msg string, data ...map[string]interface{}) + func (l *Logger) Start() (err *errs.Err) + func (l *Logger) Stop() + func (l *Logger) Warning(msg string, data ...map[string]interface{}) + type Rec struct + Data datatypes.JSONMap + Level LogLevel + Msg string + Time time.Time v0.1.0 May 30, 2022