info/CWS odfmetadata2 : new: OUStringBufferAppender and intersperse

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

info/CWS odfmetadata2 : new: OUStringBufferAppender and intersperse


          Type: info
         Title: new: OUStringBufferAppender and intersperse
     Posted by: [hidden email]
      Affected: comphelper
         TaskId: i90620
Effective from: CWS odfmetadata2
    CWS status: new

+ class OUStringBufferAppender
+ OutputIter intersperse(
    ForwardIter start, ForwardIter end, OutputIter out, T const & separator)

+ class OUStringBufferAppender

This class implements the STL output iterator interface and allows
appending to an OUStringBuffer with STL algorithms.

+ algorithm intersperse

This STL-inspired algorithm will copy a STL sequence, inserting a
separator element between every element of the source sequence.

Usage example that combines UNO Sequence STL iterators,
OUStringBufferAppender and intersperse:

::rtl::OUString convertCommaSeparated(
    ::com::sun::star::uno::Sequence< ::rtl::OUString > const& i_rSeq)
    ::rtl::OUStringBuffer buf;
        ::comphelper::stl_begin(i_rSeq), ::comphelper::stl_end(i_rSeq),
        ::rtl::OUString::createFromAscii(", "));
    return buf.makeStringAndClear();

Send feedback to [hidden email]

To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]