1 | #levels define
|
2 | info = 1
|
3 | debug = 2
|
4 | warn = 4
|
5 | error = 8
|
6 |
|
7 | text = {}
|
8 | text[info] = 'INFO '
|
9 | text[debug] = 'DEBUG'
|
10 | text[warn] = 'WARN '
|
11 | text[error] = 'ERROR'
|
12 |
|
13 | module.exports =
|
14 | text : text
|
15 | info : info
|
16 | debug : debug
|
17 | warn : warn
|
18 | error : error
|
19 | levels :
|
20 | info : info
|
21 | debug : debug
|
22 | warn : warn
|
23 | error : error
|
24 | all : error | warn | debug | info # all level const
|
25 | exception : error | warn # error levels const
|