apollo.util.interval
Class Interval

java.lang.Object
  extended by apollo.util.interval.Interval
All Implemented Interfaces:
java.lang.Comparable

public class Interval
extends java.lang.Object
implements java.lang.Comparable


Constructor Summary
Interval(int low, int high)
           
 
Method Summary
 int compareTo(java.lang.Object o)
           
 boolean equals(java.lang.Object other)
           
 int getHigh()
           
 int getLow()
           
 int hashCode()
           
 boolean overlaps(Interval other)
          Returns true if this interval overlaps the other.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Interval

public Interval(int low,
                int high)
Method Detail

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

compareTo

public int compareTo(java.lang.Object o)
Specified by:
compareTo in interface java.lang.Comparable

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

overlaps

public boolean overlaps(Interval other)
Returns true if this interval overlaps the other.


getLow

public int getLow()

getHigh

public int getHigh()