counters pairFmt examples
Vladimir Bauer
6 years ago
| 34 | 34 | // |
| 35 | 35 | // `wcc` optional WC config |
| 36 | 36 | // |
| 37 | // pairFmt example if UnitKB is chosen: | |
| 37 | // pairFmt example if unit=UnitKB: | |
| 38 | 38 | // |
| 39 | // "%.1f / %.1f" = "1.0MB / 12.0MB" or "% .1f / % .1f" = "1.0 MB / 12.0 MB" | |
| 39 | // pairFmt="%.1f / %.1f" output: "1.0MB / 12.0MB" | |
| 40 | // pairFmt="% .1f / % .1f" output: "1.0 MB / 12.0 MB" | |
| 41 | // pairFmt="%d / %d" output: "1MB / 12MB" | |
| 42 | // pairFmt="% d / % d" output: "1 MB / 12 MB" | |
| 40 | 43 | // |
| 41 | 44 | func Counters(unit int, pairFmt string, wcc ...WC) Decorator { |
| 42 | 45 | var wc WC |