1// SPDX-License-Identifier: ISC
2// Copyright (c) 2014-2020 Bitmark Inc.
3// Use of this source code is governed by an ISC
4// license that can be found in the LICENSE file.
5
6package level
7
8// simple ordering to allow <= to decide if log will be outputTarget
9const (
10	_ = iota
11	TraceLevel
12	DebugLevel
13	InfoLevel
14	WarnLevel
15	ErrorLevel
16	CriticalLevel
17	OffLevel
18)
19
20const (
21	Trace    = "trace"
22	Debug    = "debug"
23	Info     = "info"
24	Warn     = "warn"
25	Error    = "error"
26	Critical = "critical"
27	Off      = "off"
28)
29
30// This needs to correspond to seelog levels
31var ValidLevels = map[string]int{
32	Trace:    TraceLevel,
33	Debug:    DebugLevel,
34	Info:     InfoLevel,
35	Warn:     WarnLevel,
36	Error:    ErrorLevel,
37	Critical: CriticalLevel,
38	Off:      OffLevel,
39}
40