anl.aida.data
Class Range

java.lang.Object
  extended by anl.aida.data.Range

public class Range
extends java.lang.Object

class that stores a range of values along a coordinate axis

Version:
$Revision$ $Date$
See Also:
Range

Field Summary
protected  long extent
          the extent or number of cells in the set of values
protected  int origin
          the initial cell in the set of values
 
Constructor Summary
Range(int origin, long extent)
          Constructs a range for a given set of values
Range(Range range)
          Copy constructor.
 
Method Summary
 boolean equals(java.lang.Object other)
           
 long getExtent()
          Get the extent of the cells in the set of values
 int getLowerBound()
          Gets the lower bound of this range.
 int getOrigin()
          Get the origin or initial location of the cells in the set of values
 long getUpperBound()
          Gets upper bound of this range.
 int hashCode()
           
 void setExtent(long extent)
          Set the extent of the cells in the set of values
 void setOrigin(int origin)
          Set the origin or initial location of the cells in the set of values
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

origin

protected int origin
the initial cell in the set of values


extent

protected long extent
the extent or number of cells in the set of values

Constructor Detail

Range

public Range(int origin,
             long extent)
Constructs a range for a given set of values

Parameters:
-

Range

public Range(Range range)
Copy constructor.

Parameters:
range -
Method Detail

getLowerBound

public int getLowerBound()
Gets the lower bound of this range.

Returns:
the lower bound of this range.

getUpperBound

public long getUpperBound()
Gets upper bound of this range.

Returns:
upper bound of this range.

getExtent

public long getExtent()
Get the extent of the cells in the set of values

Returns:
the extent of the cells

setExtent

public void setExtent(long extent)
Set the extent of the cells in the set of values

Parameters:
extent - of the cells desired

getOrigin

public int getOrigin()
Get the origin or initial location of the cells in the set of values

Returns:
the origin of the cells

setOrigin

public void setOrigin(int origin)
Set the origin or initial location of the cells in the set of values

Parameters:
origin - of the cells desired

toString

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

hashCode

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

equals

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