JIDE 3.5.15

com.jidesoft.range
Interface Range<T>

All Known Implementing Classes:
AbstractNumericRange, AbstractRange, AggregatedRange, CategoryRange, CombinedNumericRange, IntegerRange, NumericRange, TimeRange

public interface Range<T>

Author:
Simon White (swhite@catalysoft.com)

Field Summary
static String PROPERTY_MAX
          The name of the maximum property.
static String PROPERTY_MIN
          The name of the minimum property.
 
Method Summary
 void addPropertyChangeListener(PropertyChangeListener listener)
          You can add a property change listener if you are interested to know when the range changes
 void adjust(T lower, T upper)
          Adjusts the range.
 boolean contains(T x)
          Determines whether the supplied point lies within this range.
 T lower()
           
 double maximum()
          This may be the numeric representation of upper() or it may be rounded up.
 double minimum()
          This may be the numeric representation of lower() or it may be rounded down.
 void removePropertyChangeListener(PropertyChangeListener listener)
          Remove a property change listener
 double size()
          Compute the size of the range
 T upper()
           
 

Field Detail

PROPERTY_MIN

static final String PROPERTY_MIN
The name of the minimum property. Used when firing property change events

See Also:
Constant Field Values

PROPERTY_MAX

static final String PROPERTY_MAX
The name of the maximum property. Used when firing property change events

See Also:
Constant Field Values
Method Detail

lower

T lower()
Returns:
the smallest value of the range

upper

T upper()
Returns:
the largest value of the range

adjust

void adjust(T lower,
            T upper)
Adjusts the range.

Parameters:
lower - the new smallest value of the range
upper - the new largest value of the range

minimum

double minimum()
This may be the numeric representation of lower() or it may be rounded down.

Returns:
the numeric value of the smallest value to include in the range.

maximum

double maximum()
This may be the numeric representation of upper() or it may be rounded up.

Returns:
The numeric value of the largest value to include in the range.

size

double size()
Compute the size of the range


contains

boolean contains(T x)
Determines whether the supplied point lies within this range. For continuous ranges this is interpreted as a pair of inequalities on the supplied value (i.e., min <= x <= max), but for discrete ranges the contains() method is more like a set membership test.

Parameters:
x -
Returns:
a boolean to indicate whether the supplied point lies within the range

addPropertyChangeListener

void addPropertyChangeListener(PropertyChangeListener listener)
You can add a property change listener if you are interested to know when the range changes

Parameters:
listener - the new property change listener

removePropertyChangeListener

void removePropertyChangeListener(PropertyChangeListener listener)
Remove a property change listener

Parameters:
listener - the PropertyChangeListener to remove

JIDE 3.5.15