Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::basic_formatter< CharT > Class Template Reference

Log record formatter function wrapper. More...

#include <formatter.hpp>

Inheritance diagram for boost::basic_formatter< CharT >:

Public Types

typedef void result_type
 Result type. More...
 
typedef CharT char_type
 Character type. More...
 
typedef
basic_formatting_ostream
< char_type
stream_type
 Output stream type. More...
 

Public Member Functions

 basic_formatter ()
 Default constructor. More...
 
 basic_formatter (basic_formatter const &that)
 Copy constructor. More...
 
 basic_formatter (BOOST_RV_REF(this_type) that) BOOST_NOEXCEPT
 Move constructor. More...
 
template<typename FunT >
 basic_formatter (FunT &&fun)
 Initializing constructor. More...
 
basic_formatteroperator= (BOOST_RV_REF(this_type) that) BOOST_NOEXCEPT
 Move assignment. More...
 
basic_formatteroperator= (BOOST_COPY_ASSIGN_REF(this_type) that)
 Copy assignment. More...
 
template<typename FunT >
basic_formatteroperator= (FunT &&fun)
 Initializing assignment. More...
 
result_type operator() (record_view const &rec, stream_type &strm) const
 Formatting operator. More...
 
void reset ()
 Resets the formatter to the default. More...
 
void swap (basic_formatter &that) BOOST_NOEXCEPT
 Swaps two formatters. More...
 

Detailed Description

template<typename CharT>
class boost::basic_formatter< CharT >

Log record formatter function wrapper.

Member Typedef Documentation

template<typename CharT>
typedef CharT boost::basic_formatter< CharT >::char_type

Character type.

template<typename CharT>
typedef void boost::basic_formatter< CharT >::result_type

Result type.

template<typename CharT>
typedef basic_formatting_ostream< char_type > boost::basic_formatter< CharT >::stream_type

Output stream type.

Constructor & Destructor Documentation

template<typename CharT>
boost::basic_formatter< CharT >::basic_formatter ( )
inline

Default constructor.

Creates a formatter that only outputs log message.

template<typename CharT>
boost::basic_formatter< CharT >::basic_formatter ( basic_formatter< CharT > const &  that)
inline

Copy constructor.

template<typename CharT>
boost::basic_formatter< CharT >::basic_formatter ( BOOST_RV_REF(this_type that)
inline

Move constructor.

The moved-from formatter is left in an unspecified state.

template<typename CharT>
template<typename FunT >
boost::basic_formatter< CharT >::basic_formatter ( FunT &&  fun)
inline

Initializing constructor.

Creates a formatter which will invoke the specified function object.

Member Function Documentation

template<typename CharT>
result_type boost::basic_formatter< CharT >::operator() ( record_view const &  rec,
stream_type strm 
) const
inline

Formatting operator.

Parameters
recA log record to format.
strmA stream to put the formatted characters to.
template<typename CharT>
basic_formatter& boost::basic_formatter< CharT >::operator= ( BOOST_RV_REF(this_type that)
inline

Move assignment.

The moved-from formatter is left in an unspecified state.

template<typename CharT>
basic_formatter& boost::basic_formatter< CharT >::operator= ( BOOST_COPY_ASSIGN_REF(this_type that)
inline

Copy assignment.

template<typename CharT>
template<typename FunT >
basic_formatter& boost::basic_formatter< CharT >::operator= ( FunT &&  fun)
inline

Initializing assignment.

Sets the specified function object to the formatter.

template<typename CharT>
void boost::basic_formatter< CharT >::reset ( void  )
inline

Resets the formatter to the default.

The default formatter only outputs message text.

template<typename CharT>
void boost::basic_formatter< CharT >::swap ( basic_formatter< CharT > &  that)
inline

Swaps two formatters.

Referenced by boost::basic_formatter< char_type >::operator=().


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