Printf calls v.f.logger.Printf to print to the logger. Arguments are handled in the manner of fmt.Printf.
(format string, i ...interface{})
| 105 | // Printf calls v.f.logger.Printf to print to the logger. |
| 106 | // Arguments are handled in the manner of fmt.Printf. |
| 107 | func (v Verbose) Printf(format string, i ...interface{}) { |
| 108 | if !v.ok { |
| 109 | return |
| 110 | } |
| 111 | if atomic.LoadInt32(&v.f.showLineNum) != 1 { |
| 112 | v.f.logger.Printf(format, i...) |
| 113 | } else { |
| 114 | _, fn, line, _ := runtime.Caller(1) |
| 115 | v.f.logger.Printf(fmt.Sprintf("%s => %s:%d", format, path.Base(fn), line), i...) |
| 116 | } |
| 117 | } |
| 118 | |
| 119 | // Println calls v.f.logger.Println to print to the logger. |
| 120 | // Arguments are handled in the manner of fmt.Println. |
no outgoing calls