append overloads

Synopses

Declared in <bslstl_string.h>

Append to this string each CHAR_TYPE object in the specified values initializer list, and return a reference providing modifiable access to this string.

basic_string&
append(std::initializer_list<CHAR_TYPE> values);

Append to this string the specified suffix, and return a reference providing modifiable access to this string.

basic_string&
append(basic_string const& suffix);

Append characters to this string.

basic_string&
append(CHAR_TYPE const* characterString);

Append characters to this string.

template<class STRING_VIEW_LIKE_TYPE>
basic_string&
append(STRING_VIEW_LIKE_TYPE const& suffix);

Append the specified numChars copies of the specified character to this string, and return a reference providing modifiable access to this string.

basic_string&
append(
    size_type numChars,
    CHAR_TYPE character);

Append characters to this string.

basic_string&
append(
    CHAR_TYPE const* characterString,
    size_type numChars);

Append the characters in the iterator range [first, last)].

template<class INPUT_ITER>
basic_string&
append(
    INPUT_ITER first,
    INPUT_ITER last);

Append a substring of suffix to this string.

basic_string&
append(
    basic_string const& suffix,
    size_type position,
    size_type numChars = npos);

Append characters to this string.

template<class STRING_VIEW_LIKE_TYPE>
basic_string&
append(
    STRING_VIEW_LIKE_TYPE const& suffix,
    size_type position,
    size_type numChars = npos);

Return Value

  • reference providing modifiable access to this string

  • a reference to this string

Parameters

Name

Description

values

initializer list of characters

suffix

characters to append

characterString

pointer to characters

numChars

number of characters

character

character value

first

beginning of the character range to append

last

end of the character range to append (one past last)

position

starting index in suffix

Created with MrDocs