levels: add to logger type

This commit is contained in:
Simon Eskildsen
2014-03-10 19:52:39 -04:00
parent d3ee06cc28
commit afde6aea11
5 changed files with 36 additions and 43 deletions
+7 -9
View File
@@ -2,19 +2,17 @@ package logrus
type Fields map[string]interface{}
type LevelType uint8
type Level uint8
const (
LevelPanic LevelType = iota
LevelFatal
LevelError
LevelWarn
LevelInfo
LevelDebug
Panic Level = iota
Fatal
Error
Warn
Info
Debug
)
var Level LevelType = LevelInfo
// StandardLogger is what your logrus-enabled library should take, that way
// it'll accept a stdlib logger and a logrus logger. There's no standard
// interface, this is the closest we get, unfortunately.