BloombergLP::bslim::Printer::printAttribute

printAttribute overloads

Synopses

Declared in <bslim_printer.h>

Format to the output stream supplied at construction the specified data, prefixed by the specified name. Format data based on the parameterized TYPE:

template<class TYPE>
void
printAttribute(
    bslstl::StringRef const& name,
    TYPE const& data) const;
» more...

Format name and the range [begin, end)] to the output stream.

template<class ITERATOR>
void
printAttribute(
    bslstl::StringRef const& name,
    ITERATOR const& begin,
    ITERATOR const& end) const;
» more...

Format name and [begin, end)] using printFunctionObject.

template<
    class ITERATOR,
    class PRINT_FUNCTOR>
void
printAttribute(
    bslstl::StringRef const& name,
    ITERATOR const& begin,
    ITERATOR const& end,
    PRINT_FUNCTOR const& printFunctionObject) const;
» more...

Parameters

NameDescription
nameattribute name printed before data
datavalue to format
beginbeginning of the range of values to format
endend of the range of values to format (one past the last)
printFunctionObjectfunctor used to format each element