-
Notifications
You must be signed in to change notification settings - Fork 1
/
log.go
67 lines (53 loc) · 1.25 KB
/
log.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
package log
import (
"github.com/open-horizon/edge-utilities/logger"
)
var log = logger.Logger{}
// Init Initialize Logger
func Init(parameters logger.Parameters) error {
return log.Init(parameters)
}
// ParseDestinationsList parses a list of destinations
func ParseDestinationsList(destinations string) ([]bool, bool) {
return log.ParseDestinationsList(destinations)
}
// Stop Logger
func Stop() {
log.Stop()
}
// IsLogging checks if the logging level if higher or equal to the level parameter
func IsLogging(level int) bool {
return log.IsLogging(level)
}
// Status log
func Status(format string, a ...interface{}) {
log.Status(format, a...)
}
// Fatal log
func Fatal(format string, a ...interface{}) {
log.Fatal(format, a...)
}
// Error log
func Error(format string, a ...interface{}) {
log.Error(format, a...)
}
// Warning log
func Warning(format string, a ...interface{}) {
log.Warning(format, a...)
}
// Info log
func Info(format string, a ...interface{}) {
log.Info(format, a...)
}
// Debug log
func Debug(format string, a ...interface{}) {
log.Debug(format, a...)
}
// Trace log
func Trace(format string, a ...interface{}) {
log.Trace(format, a...)
}
// Dump a struct to the log
func Dump(label string, a interface{}) {
log.Dump(label, a)
}