DataStructures
Interface Comparable

All Known Implementing Classes:
MyInteger

public interface Comparable

Protocol for Comparable objects. In Java 1.2, you can remove this file.


Method Summary
 int compareTo(Comparable rhs)
          Compare this object with rhs.
 

Method Detail

compareTo

public int compareTo(Comparable rhs)
Compare this object with rhs.
Parameters:
rhs - the second Comparable.
Returns:
0 if two objects are equal; less than zero if this object is smaller; greater than zero if this object is larger.