Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Insert() [6/20]

unsafe StringBuilder System.Text.StringBuilder.Insert ( int index,
char?[] value,
int startIndex,
int charCount )
inline

Definition at line 1393 of file StringBuilder.cs.

1394 {
1395 int length = Length;
1396 if ((uint)index > (uint)length)
1397 {
1398 throw new ArgumentOutOfRangeException("index", SR.ArgumentOutOfRange_Index);
1399 }
1400 if (value == null)
1401 {
1402 if (startIndex == 0 && charCount == 0)
1403 {
1404 return this;
1405 }
1406 throw new ArgumentNullException("value", SR.ArgumentNull_String);
1407 }
1408 if (startIndex < 0)
1409 {
1410 throw new ArgumentOutOfRangeException("startIndex", SR.ArgumentOutOfRange_StartIndex);
1411 }
1412 if (charCount < 0)
1413 {
1414 throw new ArgumentOutOfRangeException("charCount", SR.ArgumentOutOfRange_GenericPositive);
1415 }
1416 if (startIndex > value.Length - charCount)
1417 {
1418 throw new ArgumentOutOfRangeException("startIndex", SR.ArgumentOutOfRange_Index);
1419 }
1420 if (charCount > 0)
1421 {
1422 fixed (char* value2 = &value[startIndex])
1423 {
1425 }
1426 }
1427 return this;
1428 }

References System.SR.ArgumentNull_String, System.SR.ArgumentOutOfRange_GenericPositive, System.SR.ArgumentOutOfRange_Index, System.SR.ArgumentOutOfRange_StartIndex, System.charCount, System.Runtime.Serialization.Dictionary, System.index, System.Insert, System.length, System.Text.StringBuilder.Length, System.startIndex, and System.value.