[#BloombergLP-bslim-Printer-printAttribute-0e]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslim.adoc[bslim]::xref:BloombergLP/bslim/Printer.adoc[Printer]::printAttribute
:relfileprefix: ../../../
:mrdocs:

`printAttribute` overloads

== Synopses

Declared in `&lt;bslim&lowbar;printer&period;h&gt;`

Format to the output stream supplied at construction the specified `data`, prefixed by the specified `name`&period; Format `data` based on the parameterized `TYPE`&colon;


[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class TYPE&gt;
void
xref:BloombergLP/bslim/Printer/printAttribute-05.adoc[printAttribute](
    xref:BloombergLP/bslstl/StringRef.adoc[bslstl::StringRef] const& name,
    TYPE const& data) const;
----

[.small]#xref:BloombergLP/bslim/Printer/printAttribute-05.adoc[_» more&period;&period;&period;_]#

Format to the output stream supplied at construction, the specified `name` followed by the range of values starting at the specified `begin` position and ending immediately before the specified `end` position&period; The parameterized `ITERATOR` type must support `operator&plus;&plus;`, `operator&ast;`, and `operator&equals;&equals;`&period; This function will call `printValue` on each element in the range `&lsqb;begin, end)&rsqb;`&period;


[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class ITERATOR&gt;
void
xref:BloombergLP/bslim/Printer/printAttribute-01.adoc[printAttribute](
    xref:BloombergLP/bslstl/StringRef.adoc[bslstl::StringRef] const& name,
    ITERATOR const& begin,
    ITERATOR const& end) const;
----

[.small]#xref:BloombergLP/bslim/Printer/printAttribute-01.adoc[_» more&period;&period;&period;_]#

Print to the output stream supplied at construction the specified `name` and then call the specified `printFunctionObject` with the range of values starting at the specified `begin` position and ending immediately before the specified `end` position, the stream supplied at construction, `absLevel() &plus; 1`, and `spacesPerLevel()`&period; The parameterized `PRINT&lowbar;FUNCTOR` must be an invocable type whose arguments match the following function signature&colon; &grave; bsl&colon;&colon;ostream&amp; (&ast;)(bsl&colon;&colon;ostream&amp; stream, const TYPE&amp; data, int level, int spacesPerLevel) &grave;


[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    class ITERATOR,
    class PRINT&lowbar;FUNCTOR&gt;
void
xref:BloombergLP/bslim/Printer/printAttribute-00.adoc[printAttribute](
    xref:BloombergLP/bslstl/StringRef.adoc[bslstl::StringRef] const& name,
    ITERATOR const& begin,
    ITERATOR const& end,
    PRINT&lowbar;FUNCTOR const& printFunctionObject) const;
----

[.small]#xref:BloombergLP/bslim/Printer/printAttribute-00.adoc[_» more&period;&period;&period;_]#


[.small]#Created with https://www.mrdocs.com[MrDocs]#
