|
template<typename T > |
void | formatValue (std::ostream &out, const char *, const char *fmtEnd, int ntrunc, const T &value) |
|
template<typename... Args> |
*detail::FormatListN< sizeof...(Args)> | makeFormatList (const Args &... args) |
|
void | vformat (std::ostream &out, const char *fmt, FormatListRef list) |
|
template<typename... Args> |
void | format (std::ostream &out, const char *fmt, const Args &... args) |
| Format list of arguments to the stream according to given format string. More...
|
|
template<typename... Args> |
std::string | format (const char *fmt, const Args &... args) |
|
template<typename... Args> |
void | printf (const char *fmt, const Args &... args) |
| Format list of arguments to std::cout, according to the given format string. More...
|
|
template<typename... Args> |
void | printfln (const char *fmt, const Args &... args) |
|
template<typename... Args> |
std::string | format (const std::string &fmt, const Args &... args) |
|
template<typename T >
void tinyformat::formatValue |
( |
std::ostream & |
out, |
|
|
const char * |
, |
|
|
const char * |
fmtEnd, |
|
|
int |
ntrunc, |
|
|
const T & |
value |
|
) |
| |
|
inline |
Format a value into a stream, delegating to operator<< by default.
Users may override this for their own types. When this function is called, the stream flags will have been modified according to the format string. The format specification is provided in the range [fmtBegin, fmtEnd). For truncating conversions, ntrunc is set to the desired maximum number of characters, for example "%.7s" calls formatValue with ntrunc = 7.
By default, formatValue() uses the usual stream insertion operator operator<< to format the type T, with special cases for the c and p conversions.