|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--sdsu.compare.Comparer | +--sdsu.compare.ReverseOrderComparer
A comparer to reverse the order used by a Comparer. For example, an IntegerComparer will evaluate lessThen( 3, 10 ) as true. A ReverseOrder on an IntegerComparer will evaluate lessThen( 3, 10 ) as false. Useful for reversing the order of a sort list.
Method Summary | |
boolean |
equals(java.lang.Object leftOperand,
java.lang.Object rightOperand)
Returns true if the leftOperand is equal to the rightOperand. |
static Comparer |
getInstance(Comparer originalOrder)
Returns a Comparer with order reversed from the Comparer originalOrder. |
boolean |
greaterThan(java.lang.Object leftOperand,
java.lang.Object rightOperand)
Returns true if the leftOperand is greater than the rightOperand. |
boolean |
greaterThanOrEqual(java.lang.Object leftOperand,
java.lang.Object rightOperand)
Returns true if the leftOperand is greater than or equal the rightOperand. |
boolean |
lessThan(java.lang.Object leftOperand,
java.lang.Object rightOperand)
Returns true if the leftOperand is less than the rightOperand. |
boolean |
lessThanOrEqual(java.lang.Object leftOperand,
java.lang.Object rightOperand)
Returns true if the leftOperand is less than or equal to the rightOperand. |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Method Detail |
public static Comparer getInstance(Comparer originalOrder)
public final boolean lessThan(java.lang.Object leftOperand, java.lang.Object rightOperand) throws java.lang.ClassCastException
public final boolean greaterThan(java.lang.Object leftOperand, java.lang.Object rightOperand) throws java.lang.ClassCastException
public final boolean equals(java.lang.Object leftOperand, java.lang.Object rightOperand) throws java.lang.ClassCastException
public final boolean lessThanOrEqual(java.lang.Object leftOperand, java.lang.Object rightOperand) throws java.lang.ClassCastException
public final boolean greaterThanOrEqual(java.lang.Object leftOperand, java.lang.Object rightOperand) throws java.lang.ClassCastException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |