CLRA 0.1.2

com.clra.rowing
Class DefaultRowingSessionComparator

java.lang.Object
  |
  +--com.clra.rowing.DefaultRowingSessionComparator
All Implemented Interfaces:
Comparator, ISerializableComparator, Serializable

public class DefaultRowingSessionComparator
extends Object
implements ISerializableComparator

Compares a rowing session with another rowing session for order.

Version:
$Revision: 1.2 $ $Date: 2002/02/18 18:03:58 $
Author:
Rick Hall
See Also:
Serialized Form

Constructor Summary
DefaultRowingSessionComparator()
           
 
Method Summary
 int compare(Object o1, Object o2)
           
static int staticCompare(Object o1, Object o2)
          Compares a rowing session with another rowing session for order.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

DefaultRowingSessionComparator

public DefaultRowingSessionComparator()
Method Detail

staticCompare

public static int staticCompare(Object o1,
                                Object o2)
Compares a rowing session with another rowing session for order. Rowing sessions are compared by date, state, type, level, and id, in that order.

The current implementation compares IRowingSession and RowingSessionSnapshot instances..

Returns:
a negative integer, zero, or a positive integer as the first rowing session is less than, equal to, or greater than the second rowing session.
Throws:
ClassCastException - if either object is not a rowing session.
IllegalStateException - if either rowing session throws a RemoteException.

compare

public int compare(Object o1,
                   Object o2)
Specified by:
compare in interface Comparator
See Also:
staticCompare(Object,Object)

CLRA 0.1.2