SoPlex Documentation
Loading...
Searching...
No Matches
arg_formatter< Range > Class Template Reference

#include <format.h>

Inheritance diagram for arg_formatter< Range >:
arg_formatter_base< Range, ErrorHandler >

Public Types

using range = Range
 
using iterator = typename base::iterator
 
using format_specs = typename base::format_specs
 
- Public Types inherited from arg_formatter_base< Range, ErrorHandler >
using char_type = typename Range::value_type
 
using iterator = typename Range::iterator
 
using format_specs = basic_format_specs<char_type>
 

Public Member Functions

 arg_formatter (context_type &ctx, basic_format_parse_context< char_type > *parse_ctx=nullptr, format_specs *specs=nullptr)
 
iterator operator() (typename basic_format_arg< context_type >::handle handle)
 
- Public Member Functions inherited from arg_formatter_base< Range, ErrorHandler >
 arg_formatter_base (Range r, format_specs *s, locale_ref loc)
 
iterator operator() (monostate)
 
template<typename T , FMT_ENABLE_IF(is_integral< T >::value) >
iterator operator() (T value)
 
iterator operator() (char_type value)
 
iterator operator() (bool value)
 
template<typename T , FMT_ENABLE_IF(std::is_floating_point< T >::value) >
iterator operator() (T value)
 
iterator operator() (const char_type *value)
 
iterator operator() (basic_string_view< char_type > value)
 
iterator operator() (const void *value)
 

Private Types

using char_type = typename Range::value_type
 
using base = internal::arg_formatter_base<Range>
 
using context_type = basic_format_context<typename base::iterator, char_type>
 

Private Attributes

context_typectx_
 
basic_format_parse_context< char_type > * parse_ctx_
 

Additional Inherited Members

- Protected Member Functions inherited from arg_formatter_base< Range, ErrorHandler >
writer_typewriter ()
 
FMT_DEPRECATED format_specsspec ()
 
format_specsspecs ()
 
iterator out ()
 
void write (bool value)
 
void write (const char_type *value)
 

Detailed Description

template<typename Range>
class arg_formatter< Range >

The default argument formatter.

Definition at line 2660 of file format.h.

Member Typedef Documentation

◆ base

template<typename Range >
using base = internal::arg_formatter_base<Range>
private

Definition at line 2663 of file format.h.

◆ char_type

template<typename Range >
using char_type = typename Range::value_type
private

Definition at line 2662 of file format.h.

◆ context_type

template<typename Range >
using context_type = basic_format_context<typename base::iterator, char_type>
private

Definition at line 2664 of file format.h.

◆ format_specs

template<typename Range >
using format_specs = typename base::format_specs

Definition at line 2672 of file format.h.

◆ iterator

template<typename Range >
using iterator = typename base::iterator

Definition at line 2671 of file format.h.

◆ range

template<typename Range >
using range = Range

Definition at line 2670 of file format.h.

Constructor & Destructor Documentation

◆ arg_formatter()

template<typename Range >
arg_formatter ( context_type & ctx,
basic_format_parse_context< char_type > * parse_ctx = nullptr,
format_specs * specs = nullptr )
explicit

\rst Constructs an argument formatter object. ctx* is a reference to the formatting context, specs* contains format specifier information for standard argument types. \endrst

Definition at line 2681 of file format.h.

Member Function Documentation

◆ operator()()

template<typename Range >
iterator operator() ( typename basic_format_arg< context_type >::handle handle)

Formats an argument of a user-defined type.

Definition at line 2692 of file format.h.

References basic_format_arg< Context >::handle::format(), and basic_format_context< OutputIt, Char >::out().

Member Data Documentation

◆ ctx_

template<typename Range >
context_type& ctx_
private

Definition at line 2666 of file format.h.

◆ parse_ctx_

template<typename Range >
basic_format_parse_context<char_type>* parse_ctx_
private

Definition at line 2667 of file format.h.