Sprintf formats according to a format specifier and returns the resulting string.
(format string, a ...any)
| 228 | |
| 229 | // Sprintf formats according to a format specifier and returns the resulting string. |
| 230 | func (p PrefixPrinter) Sprintf(format string, a ...any) string { |
| 231 | if p.Debugger && !PrintDebugMessages { |
| 232 | return "" |
| 233 | } |
| 234 | return p.Sprint(Sprintf(format, a...)) |
| 235 | } |
| 236 | |
| 237 | // Sprintfln formats according to a format specifier and returns the resulting string. |
| 238 | // Spaces are always added between operands and a newline is appended. |