Insert()

StringBuilder::Insert(int, const String&) method

Inserts string into builder’s fixed position.

StringBuilder * System::Text::StringBuilder::Insert(int startIndex, const String &str)

Arguments

ParameterTypeDescription
startIndexintPosition to insert characters into.
strconst String&String to insert.

Return Value

This pointer.

StringBuilder::Insert(int32_t, const String&, int32_t) method

Inserts repeated string into builder’s fixed position.

StringBuilder * System::Text::StringBuilder::Insert(int32_t index, const String &value, int32_t count)

Arguments

ParameterTypeDescription
indexint32_tPosition to insert characters into.
valueconst String&String to insert.
countint32_tHow many times to repeat value string.

Return Value

This pointer.

StringBuilder::Insert(int, char_t) method

Inserts character into builder’s fixed position.

StringBuilder * System::Text::StringBuilder::Insert(int startIndex, char_t ch)

Arguments

ParameterTypeDescription
startIndexintPosition to insert characters into.
chchar_tCharacter to insert.

Return Value

This pointer.

StringBuilder::Insert(int, const System::ArrayPtr<char_t>&, int, int) method

Inserts characters into builder’s fixed position.

StringBuilder * System::Text::StringBuilder::Insert(int index, const System::ArrayPtr<char_t> &chars, int startIndex, int charCount)

Arguments

ParameterTypeDescription
indexintPosition to insert characters into.
charsconst System::ArrayPtr<char_t>&Array to insert slice from.
startIndexintArray slice beginning index.
charCountintArray slice length.

Return Value

This pointer.

StringBuilder::Insert(int, T) method

Inserts value into builder’s fixed position.

template<typename T> std::enable_if<std::is_arithmetic<T>::value, StringBuilder *>::type System::Text::StringBuilder::Insert(int startIndex, T value)

Template parameters

ParameterDescription
Parametertype.

Arguments

ParameterTypeDescription
startIndexintPosition to insert characters into.
valueTValue to format and insert.

Return Value

This pointer.

See Also