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

◆ Sort() [5/5]

virtual void System.Collections.ArrayList.Sort ( int index,
int count,
IComparer? comparer )
inlinevirtualinherited

Definition at line 2725 of file ArrayList.cs.

2726 {
2727 if (index < 0)
2728 {
2729 throw new ArgumentOutOfRangeException("index", SR.ArgumentOutOfRange_NeedNonNegNum);
2730 }
2731 if (count < 0)
2732 {
2733 throw new ArgumentOutOfRangeException("count", SR.ArgumentOutOfRange_NeedNonNegNum);
2734 }
2735 if (_size - index < count)
2736 {
2737 throw new ArgumentException(SR.Argument_InvalidOffLen);
2738 }
2739 Array.Sort(_items, index, count, comparer);
2740 _version++;
2741 }

References System.Collections.ArrayList._items, System.Collections.ArrayList._size, System.Collections.ArrayList._version, System.SR.Argument_InvalidOffLen, System.SR.ArgumentOutOfRange_NeedNonNegNum, System.comparer, System.count, System.index, and System.Array.Sort().