forked from xuperchain/burrow
-
Notifications
You must be signed in to change notification settings - Fork 0
/
logger.go
34 lines (27 loc) · 760 Bytes
/
logger.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
package tendermint
import (
"github.com/hyperledger/burrow/logging"
"github.com/tendermint/tendermint/libs/log"
)
type tendermintLogger struct {
logger *logging.Logger
}
func NewLogger(logger *logging.Logger) log.Logger {
return &tendermintLogger{
logger: logger,
}
}
func (tml *tendermintLogger) Info(msg string, keyvals ...interface{}) {
tml.logger.InfoMsg(msg, keyvals...)
}
func (tml *tendermintLogger) Error(msg string, keyvals ...interface{}) {
tml.logger.InfoMsg(msg, keyvals...)
}
func (tml *tendermintLogger) Debug(msg string, keyvals ...interface{}) {
tml.logger.TraceMsg(msg, keyvals...)
}
func (tml *tendermintLogger) With(keyvals ...interface{}) log.Logger {
return &tendermintLogger{
logger: tml.logger.With(keyvals...),
}
}