Click or drag to resize
TripleTFirst, TSecond, TThirdCompareTo Method

Compares this triple to another triple of the some type. The triples are compared by using the IComparable<T> or IComparable interface on TFirst, TSecond, and TThird. The triples are compared by their first elements first, if their first elements are equal, then they are compared by their second elements. If their second elements are also equal, then they are compared by their third elements.

If TFirst, TSecond, or TThird does not implement IComparable<T> or IComparable, then an NotSupportedException is thrown, because the triples cannot be compared.

Namespace: X3Platform.Collections
Assembly: X3Platform.Support (in X3Platform.Support.dll) Version: 1.0.0.0 (2.0.0.0)
Syntax
public int CompareTo(
	Triple<TFirst, TSecond, TThird> other
)

Parameters

other
Type: X3Platform.CollectionsTripleTFirst, TSecond, TThird
The triple to compare to.

Return Value

Type: Int32
An integer indicating how this triple compares to other. Less than zero indicates this triple is less than other. Zero indicate this triple is equals to other. Greater than zero indicates this triple is greater than other.

Implements

IComparableTCompareTo(T)
Exceptions
ExceptionCondition
NotSupportedExceptionEither FirstSecond, TSecond, or TThird is not comparable via the IComparable<T> or IComparable interfaces.
See Also