xtd 0.2.0
Loading...
Searching...
No Matches

◆ join() [1/3]

template<typename char_t , typename traits_t , typename allocator_t >
template<typename collection_t >
static basic_string xtd::basic_string< char_t, traits_t, allocator_t >::join ( const basic_string< char_t, traits_t, allocator_t >  separator,
const collection_t &  values 
)
inlinestaticnoexcept

Concatenates a specified separator basic_string between each element of a specified object array, yielding a single concatenated basic_string.

Parameters
separatorA basic_string separator.
valuesAn array of Object.
Returns
A basic_string consisting of the elements of value interspersed with the separator basic_string.
Remarks
For example if separator is ", " and the elements of value are "red", "blue", "green", and "yellow", Join(separator, value) returns "red, blue, green, yellow".
stream << operator is called on each object to generate the content.
Examples
test_forms.cpp, and uri.cpp.