log/std_logger.go   A
last analyzed

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
cc 3
eloc 9
dl 0
loc 20
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A log.*StdLogger.Infof 0 2 1
A log.*StdLogger.Log 0 2 1
A log.*StdLogger.Errorf 0 2 1
1
package log
2
3
import "log"
4
5
// StdLogger use standard log package.
6
type StdLogger struct{}
7
8
// Log logging the SDK's log.
9
func (*StdLogger) Log(v ...interface{}) {
10
	log.Println(v...)
11
}
12
13
// Infof logging information.
14
func (*StdLogger) Infof(service, format string, v ...interface{}) {
15
	log.Printf("[INFO] ["+service+"] "+format, v...)
0 ignored issues
show
introduced by
can't check non-constant format in call to Printf
Loading history...
16
}
17
18
// Errorf logging error information.
19
func (*StdLogger) Errorf(service, format string, v ...interface{}) {
20
	log.Printf("[ERROR] ["+service+"] "+format, v...)
0 ignored issues
show
introduced by
can't check non-constant format in call to Printf
Loading history...
21
}
22