SoPlex Documentation
Loading...
Searching...
No Matches
basic_format_context< OutputIt, Char > Class Template Reference

#include <core.h>

Public Types

using char_type = Char
 
using iterator = OutputIt
 
using format_arg = basic_format_arg<basic_format_context>
 
template<typename T >
using formatter_type = formatter<T, char_type>
 

Public Member Functions

 basic_format_context (const basic_format_context &)=delete
 
void operator= (const basic_format_context &)=delete
 
 basic_format_context (OutputIt out, basic_format_args< basic_format_context > ctx_args, internal::locale_ref loc=internal::locale_ref())
 
format_arg arg (int id) const
 
format_arg arg (basic_string_view< char_type > name)
 
internal::error_handler error_handler ()
 
void on_error (const char *message)
 
iterator out ()
 
void advance_to (iterator it)
 
internal::locale_ref locale ()
 

Private Attributes

OutputIt out_
 
basic_format_args< basic_format_contextargs_
 
internal::arg_map< basic_format_contextmap_
 
internal::locale_ref loc_
 

Detailed Description

template<typename OutputIt, typename Char>
class basic_format_context< OutputIt, Char >

Definition at line 1135 of file core.h.

Member Typedef Documentation

◆ char_type

template<typename OutputIt , typename Char >
using char_type = Char

The character type for the output.

Definition at line 1138 of file core.h.

◆ format_arg

template<typename OutputIt , typename Char >
using format_arg = basic_format_arg<basic_format_context>

Definition at line 1148 of file core.h.

◆ formatter_type

template<typename OutputIt , typename Char >
template<typename T >
using formatter_type = formatter<T, char_type>

Definition at line 1149 of file core.h.

◆ iterator

template<typename OutputIt , typename Char >
using iterator = OutputIt

Definition at line 1147 of file core.h.

Constructor & Destructor Documentation

◆ basic_format_context() [1/2]

template<typename OutputIt , typename Char >
basic_format_context ( const basic_format_context< OutputIt, Char > & )
delete

◆ basic_format_context() [2/2]

template<typename OutputIt , typename Char >
basic_format_context ( OutputIt out,
basic_format_args< basic_format_context< OutputIt, Char > > ctx_args,
internal::locale_ref loc = internal::locale_ref() )

Constructs a basic_format_context object. References to the arguments are stored in the object so make sure they have appropriate lifetimes.

Definition at line 1157 of file core.h.

Member Function Documentation

◆ advance_to()

template<typename OutputIt , typename Char >
void advance_to ( iterator it)

Definition at line 1175 of file core.h.

References basic_format_context< OutputIt, Char >::out_.

◆ arg() [1/2]

template<typename Range , typename Char >
basic_format_context< Range, Char >::format_arg arg ( basic_string_view< char_type > name)

Definition at line 3077 of file format.h.

References arg(), and internal::none_type.

◆ arg() [2/2]

template<typename OutputIt , typename Char >
format_arg arg ( int id) const

◆ error_handler()

template<typename OutputIt , typename Char >
internal::error_handler error_handler ( )

Definition at line 1168 of file core.h.

Referenced by basic_format_context< OutputIt, Char >::on_error().

◆ locale()

template<typename OutputIt , typename Char >
internal::locale_ref locale ( )

Definition at line 1177 of file core.h.

References basic_format_context< OutputIt, Char >::loc_.

◆ on_error()

template<typename OutputIt , typename Char >
void on_error ( const char * message)

◆ operator=()

template<typename OutputIt , typename Char >
void operator= ( const basic_format_context< OutputIt, Char > & )
delete

◆ out()

template<typename OutputIt , typename Char >
iterator out ( )

Member Data Documentation

◆ args_

template<typename OutputIt , typename Char >
basic_format_args<basic_format_context> args_
private

Definition at line 1142 of file core.h.

Referenced by basic_format_context< OutputIt, Char >::arg().

◆ loc_

template<typename OutputIt , typename Char >
internal::locale_ref loc_
private

Definition at line 1144 of file core.h.

Referenced by basic_format_context< OutputIt, Char >::locale().

◆ map_

template<typename OutputIt , typename Char >
internal::arg_map<basic_format_context> map_
private

Definition at line 1143 of file core.h.

◆ out_

template<typename OutputIt , typename Char >
OutputIt out_
private