.TH "std::ostream_iterator< _Tp, _CharT, _Traits >" 3cxx "Wed Jul 28 2021" "libstdc++" \" -*- nroff -*- .ad l .nh .SH NAME std::ostream_iterator< _Tp, _CharT, _Traits > \- Provides output iterator semantics for streams\&. .SH SYNOPSIS .br .PP .PP Inherits \fBstd::iterator< output_iterator_tag, void, void, void, void >\fP\&. .SS "Public Types" .in +1c .ti -1c .RI "typedef void \fBdifference_type\fP" .br .RI "Distance between iterators is represented as this type\&. " .ti -1c .RI "typedef \fBoutput_iterator_tag\fP \fBiterator_category\fP" .br .RI "One of the \fBtag types\fP\&. " .ti -1c .RI "typedef void \fBpointer\fP" .br .RI "This type represents a pointer-to-value_type\&. " .ti -1c .RI "typedef void \fBreference\fP" .br .RI "This type represents a reference-to-value_type\&. " .ti -1c .RI "typedef void \fBvalue_type\fP" .br .RI "The type 'pointed to' by the iterator\&. " .in -1c .PP .RI "\fB\fP" .br .in +1c .in +1c .ti -1c .RI "typedef _CharT \fBchar_type\fP" .br .RI "Public typedef\&. " .ti -1c .RI "typedef _Traits \fBtraits_type\fP" .br .RI "Public typedef\&. " .ti -1c .RI "typedef \fBbasic_ostream\fP< _CharT, _Traits > \fBostream_type\fP" .br .RI "Public typedef\&. " .in -1c .in -1c .SS "Public Member Functions" .in +1c .ti -1c .RI "\fBostream_iterator\fP (const \fBostream_iterator\fP &__obj)" .br .RI "Copy constructor\&. " .ti -1c .RI "\fBostream_iterator\fP (\fBostream_type\fP &__s)" .br .RI "Construct from an ostream\&. " .ti -1c .RI "\fBostream_iterator\fP (\fBostream_type\fP &__s, const _CharT *__c)" .br .ti -1c .RI "\fBostream_iterator\fP & \fBoperator*\fP ()" .br .ti -1c .RI "\fBostream_iterator\fP & \fBoperator++\fP ()" .br .ti -1c .RI "\fBostream_iterator\fP & \fBoperator++\fP (int)" .br .ti -1c .RI "\fBostream_iterator\fP & \fBoperator=\fP (const _Tp &__value)" .br .RI "Writes \fIvalue\fP to underlying ostream using operator<<\&. If constructed with delimiter string, writes delimiter to ostream\&. " .ti -1c .RI "\fBostream_iterator\fP & \fBoperator=\fP (const \fBostream_iterator\fP &)=default" .br .in -1c .SH "Detailed Description" .PP .SS "template> .br class std::ostream_iterator< _Tp, _CharT, _Traits >" Provides output iterator semantics for streams\&. This class provides an iterator to write to an ostream\&. The type Tp is the only type written by this iterator and there must be an operator<<(Tp) defined\&. .PP \fBTemplate Parameters\fP .RS 4 \fI_Tp\fP The type to write to the ostream\&. .br \fI_CharT\fP The ostream char_type\&. .br \fI_Traits\fP The ostream char_traits\&. .RE .PP .PP Definition at line 176 of file stream_iterator\&.h\&. .SH "Member Typedef Documentation" .PP .SS "template> typedef _CharT \fBstd::ostream_iterator\fP< _Tp, _CharT, _Traits >::\fBchar_type\fP" .PP Public typedef\&. .PP Definition at line 185 of file stream_iterator\&.h\&. .SS "typedef void \fBstd::iterator\fP< \fBoutput_iterator_tag\fP , void , void , void , void >::\fBdifference_type\fP\fC [inherited]\fP" .PP Distance between iterators is represented as this type\&. .PP Definition at line 134 of file stl_iterator_base_types\&.h\&. .SS "typedef \fBoutput_iterator_tag\fP \fBstd::iterator\fP< \fBoutput_iterator_tag\fP , void , void , void , void >::\fBiterator_category\fP\fC [inherited]\fP" .PP One of the \fBtag types\fP\&. .PP Definition at line 130 of file stl_iterator_base_types\&.h\&. .SS "template> typedef \fBbasic_ostream\fP<_CharT, _Traits> \fBstd::ostream_iterator\fP< _Tp, _CharT, _Traits >::\fBostream_type\fP" .PP Public typedef\&. .PP Definition at line 187 of file stream_iterator\&.h\&. .SS "typedef void \fBstd::iterator\fP< \fBoutput_iterator_tag\fP , void , void , void , void >::\fBpointer\fP\fC [inherited]\fP" .PP This type represents a pointer-to-value_type\&. .PP Definition at line 136 of file stl_iterator_base_types\&.h\&. .SS "typedef void \fBstd::iterator\fP< \fBoutput_iterator_tag\fP , void , void , void , void >::\fBreference\fP\fC [inherited]\fP" .PP This type represents a reference-to-value_type\&. .PP Definition at line 138 of file stl_iterator_base_types\&.h\&. .SS "template> typedef _Traits \fBstd::ostream_iterator\fP< _Tp, _CharT, _Traits >::\fBtraits_type\fP" .PP Public typedef\&. .PP Definition at line 186 of file stream_iterator\&.h\&. .SS "typedef void \fBstd::iterator\fP< \fBoutput_iterator_tag\fP , void , void , void , void >::\fBvalue_type\fP\fC [inherited]\fP" .PP The type 'pointed to' by the iterator\&. .PP Definition at line 132 of file stl_iterator_base_types\&.h\&. .SH "Constructor & Destructor Documentation" .PP .SS "template> \fBstd::ostream_iterator\fP< _Tp, _CharT, _Traits >::\fBostream_iterator\fP (\fBostream_type\fP & __s)\fC [inline]\fP" .PP Construct from an ostream\&. .PP Definition at line 201 of file stream_iterator\&.h\&. .SS "template> \fBstd::ostream_iterator\fP< _Tp, _CharT, _Traits >::\fBostream_iterator\fP (\fBostream_type\fP & __s, const _CharT * __c)\fC [inline]\fP" Construct from an ostream\&. .PP The delimiter string \fIc\fP is written to the stream after every Tp written to the stream\&. The delimiter is not copied, and thus must not be destroyed while this iterator is in use\&. .PP \fBParameters\fP .RS 4 \fI__s\fP Underlying ostream to write to\&. .br \fI__c\fP CharT delimiter string to insert\&. .RE .PP .PP Definition at line 214 of file stream_iterator\&.h\&. .SS "template> \fBstd::ostream_iterator\fP< _Tp, _CharT, _Traits >::\fBostream_iterator\fP (const \fBostream_iterator\fP< _Tp, _CharT, _Traits > & __obj)\fC [inline]\fP" .PP Copy constructor\&. .PP Definition at line 218 of file stream_iterator\&.h\&. .SH "Member Function Documentation" .PP .SS "template> \fBostream_iterator\fP& \fBstd::ostream_iterator\fP< _Tp, _CharT, _Traits >::operator= (const _Tp & __value)\fC [inline]\fP" .PP Writes \fIvalue\fP to underlying ostream using operator<<\&. If constructed with delimiter string, writes delimiter to ostream\&. .PP Definition at line 228 of file stream_iterator\&.h\&. .SH "Author" .PP Generated automatically by Doxygen for libstdc++ from the source code\&.