@ Override public int compareTo ( Tuple other ) { int temp = compareItems ( other ) ; if ( temp != 0 ) return temp ; // All compared elements were equal. // If 'other' is of another class than 'this', it must have // more elements, and therefore it is considered greatest; // otherwise the tuples are equal. return getClass ( ) == other . getClass ( ) ? 0 : - 1 ; }
Compares this Tuple with another Tuple for order .