Method IsSorted
IsSorted()
Check if this list is sorted according to the default sorting order for the item type T, as defined by the C5.Comparer`1 class
Declaration
bool IsSorted()
Returns
Type | Description |
---|---|
System.Boolean | True if the list is sorted, else false. |
Exceptions
Type | Condition |
---|---|
NotComparableException | if T is not comparable |
IsSorted(Collections.Generic.IComparer<T>)
Check if this list is sorted according to a specific sorting order.
Declaration
bool IsSorted(Collections.Generic.IComparer<T> comparer)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IComparer<T> | comparer | The comparer defining the sorting order. |
Returns
Type | Description |
---|---|
System.Boolean | True if the list is sorted, else false. |