BDE 4.39.x Production Release
Loading...
Searching...
No Matches
bdlt::Literal_SpecifierFormatter< t_CHAR > Class Template Reference

#include <bdlt_literal_specifierformatter.h>

Detailed Description

template<class t_CHAR>
class bdlt::Literal_SpecifierFormatter< t_CHAR >

This class does parsing and output of sequences whose corresponding output is independent of the type and value of the object being formatted.

See bdlt_literal_specifierformatter

Public Member Functions

BSLS_KEYWORD_CONSTEXPR_CPP20 Literal_SpecifierFormatter ()
 
BSLS_KEYWORD_CONSTEXPR_CPP20 bool parseNextSpecifier (StringView *spec)
 
template<class t_ITERATOR >
bool formatNextSpecifier (StringView *spec, t_ITERATOR *outIt) const
 
int totalWidth () const
 

Constructor & Destructor Documentation

◆ Literal_SpecifierFormatter()

template<class t_CHAR >
BSLS_KEYWORD_CONSTEXPR_CPP20 bdlt::Literal_SpecifierFormatter< t_CHAR >::Literal_SpecifierFormatter ( )

Create an object with totalWidth set to 0.

Member Function Documentation

◆ formatNextSpecifier()

template<class t_CHAR >
template<class t_ITERATOR >
bool bdlt::Literal_SpecifierFormatter< t_CHAR >::formatNextSpecifier ( StringView spec,
t_ITERATOR *  outIt 
) const
inline

Examine the front character of the specified spec. If that character matches any of those recognized by this specifier formatter, perform the sort of output indicated by that character off of spec and return true, otherwise return false.

◆ parseNextSpecifier()

template<class t_CHAR >
BSLS_KEYWORD_CONSTEXPR_CPP20 bool bdlt::Literal_SpecifierFormatter< t_CHAR >::parseNextSpecifier ( StringView spec)

Parse the front character of the specified spec. If that character matches any of those recognized by this specifier formatter, increment d_totalWidth, pop the first character off of spec and return true, otherwise return false.

Precondition
The behavior is undefined if *spec is empty.

◆ totalWidth()

template<class t_CHAR >
int bdlt::Literal_SpecifierFormatter< t_CHAR >::totalWidth ( ) const
inline

Return the total width of the output anticipated from all the previous calls to parseNextSpecifier.


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