STD::EXPERIMENTAL::OSTREAM_JOINER(3cxx)
π std::experimental::ostream_joiner< _DelimT, _CharT, _Traits > π
okay bestie, you're in the 3cxx manual, and this is the page for the output iterator that inserts a delimiter between elements. Itβs giving βjoin things with a cute little separatorβ energy, and honestly? iconic. π
πΈ NAME πΈ
std::experimental::ostream_joiner< _DelimT, _CharT, _Traits > β Output iterator that inserts a delimiter between elements. Thatβs the name, thatβs the vibe, periodt.
β¨ SYNOPSIS β¨
#include <iterator>
π Public Types π
typedef _CharT char_typeβchar_typeis literally_CharT, bestie.typedef void difference_typeβdifference_typeisvoid. no cap.typedef output_iterator_tag iterator_categoryβ the category isoutput_iterator_tag, slay.typedef basic_ostream< _CharT, _Traits > ostream_typeβostream_typeisbasic_ostream< _CharT, _Traits >.typedef void pointerβpointerisvoid.typedef void referenceβreferenceisvoid.typedef _Traits traits_typeβtraits_typeis_Traits.typedef void value_typeβvalue_typeisvoid. yes, another one.
π Public Member Functions π
ostream_joiner (ostream_type &__os, _DelimT &&__delimiter) noexcept(is_nothrow_move_constructible_v< _DelimT >)β constructor that takes anostream_type &__osand a_DelimT &&__delimiter; itsnoexceptis tied tois_nothrow_move_constructible_v< _DelimT >.ostream_joiner (ostream_type &__os, const _DelimT &__delimiter) noexcept(is_nothrow_copy_constructible_v< _DelimT >)β constructor that takes anostream_type &__osand aconst _DelimT &__delimiter; itsnoexceptis tied tois_nothrow_copy_constructible_v< _DelimT >.ostream_joiner & operator* () noexceptβ dereference operator, returnsostream_joiner &, and itβsnoexcept.ostream_joiner & operator++ () noexceptβ pre-increment, returnsostream_joiner &, stillnoexcept.ostream_joiner & operator++ (int) noexceptβ post-increment, returnsostream_joiner &, alsonoexcept.template<typename _Tp > ostream_joiner & operator= (const _Tp &__value)β assignment template takingconst _Tp &__value, returnsostream_joiner &.
π¦ Detailed Description π¦
Hereβs the class declaration exactly as the page gives it, line breaks and all β including that little quote mark before Output, because I am not touching the source text, bestie:
template<typename _DelimT, typename _CharT = char, typename _Traits =
char_traits<_CharT>>
class std::experimental::ostream_joiner< _DelimT, _CharT, _Traits
>"Output iterator that inserts a delimiter between elements.
So yeah: template<typename _DelimT, typename _CharT = char, typename _Traits = char_traits<_CharT>>, class std::experimental::ostream_joiner< _DelimT, _CharT, _Traits >, and the description is that itβs an output iterator that inserts a delimiter between elements. π
π Author π
Generated automatically by Doxygen for libstdc++ from the source code.
So no human author handwriting this one β Doxygen did its little robot chores π€β¨.
Source/version and date sign-off, because we do not copy footers around here: this page is from libstdc++ and the 3cxx manual. The footer doesnβt show a date, so Iβm not inventing one β thatβs the honest tea. bye bestie, go insert some delimiters responsibly π«Άπ
π¦ where this page comes from
- ubuntu noble: libstdc++-14-doc 14-20240412-0ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms