PairTFirst, TSecondCompareTo Method |
Compares this pair to another pair of the some type. The pairs are compared by using the IComparable<T> or IComparable interface on TFirst and TSecond. The pairs are compared by their first elements first, if their first elements are equal, then they are compared by their second elements.
If either TFirst or TSecond does not implement IComparable<T> or IComparable, then an NotSupportedException is thrown, because the pairs cannot be compared.
Namespace: X3Platform.Collections
Exception | Condition |
---|---|
NotSupportedException | Either FirstSecond or TSecond is not comparable via the IComparable<T> or IComparable interfaces. |