libfly  6.2.2
C++20 utility library for Linux, macOS, and Windows
fly::detail::BasicFormatContext< OutputIterator, CharType > Class Template Reference

#include <format_context.hpp>

Public Types

using char_type = CharType
 
template<typename T >
using formatter_type = fly::Formatter< std::remove_cvref_t< T >, CharType >
 

Public Member Functions

template<typename... Parameters>
constexpr BasicFormatContext (OutputIterator out, const BasicFormatParameters< BasicFormatContext, Parameters... > &parameters) noexcept
 
FormatParameter arg (std::size_t index) const
 
OutputIterator & out ()
 

Detailed Description

template<typename OutputIterator, fly::StandardCharacter CharType>
class fly::detail::BasicFormatContext< OutputIterator, CharType >

Provides access to the formatting state consisting of the format parameters, replacement fields and the output iterator.

Author
Timothy Flynn (trfly.nosp@m.nn89.nosp@m.@pm.m.nosp@m.e)
Version
April 4, 2021

Constructor & Destructor Documentation

◆ BasicFormatContext()

template<typename OutputIterator , fly::StandardCharacter CharType>
template<typename... Parameters>
constexpr fly::detail::BasicFormatContext< OutputIterator, CharType >::BasicFormatContext ( OutputIterator  out,
const BasicFormatParameters< BasicFormatContext< OutputIterator, CharType >, Parameters... > &  parameters 
)
constexprnoexcept

Constructor.

Parameters
outThe output iterator into which the formatted value should be written.
parametersThe format parameters created with |make_format_parameters|.

Member Function Documentation

◆ arg()

template<typename OutputIterator , fly::StandardCharacter CharType>
auto fly::detail::BasicFormatContext< OutputIterator, CharType >::arg ( std::size_t  index) const
inline

Get the object holding the format parameter at the specified index. If the index is invalid, returns a format parameter holding |MonoState|.

Parameters
indexThe index to lookup.
Returns
The format parameter at the specified index.

◆ out()

template<typename OutputIterator , fly::StandardCharacter CharType>
OutputIterator & fly::detail::BasicFormatContext< OutputIterator, CharType >::out
inline
Returns
The output iterator into which the formatted value should be written.

The documentation for this class was generated from the following file: