Template Class basic_printf_context

Class Documentation

template<typename OutputIt, typename Char>
class fmt::v6::basic_printf_context

This template formats data and writes the output to a writer.

Public Types

using char_type = Char

The character type for the output.

using iterator = OutputIt
using format_arg = basic_format_arg<basic_printf_context>
using parse_context_type = basic_printf_parse_context<Char>
template<typename T>
using formatter_type = printf_formatter<T>

Public Functions

basic_printf_context(OutputIt out, basic_string_view<char_type> format_str, basic_format_args<basic_printf_context> args)

Constructs a printf_context object. References to the arguments and the writer are stored in the context object so make sure they have appropriate lifetimes.

OutputIt out()
void advance_to(OutputIt it)
internal::locale_ref locale()
format_arg arg(int id) const
parse_context_type &parse_context()
void on_error(const char *message)
template<typename ArgFormatter = printf_arg_formatter<buffer_range<Char>>>
OutputIt format()

Formats stored arguments and writes the output to the range.