|
Eclipse Draw2d 3.7 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface RangeModel
This interface represents a range of possible values as well as the current values. There is a minumum and maximum value, a current value, and the extent. One use for a RangeModel is a scrollbar. There is a minimum value (the top of the scrollbar), a maximum value (the bottom of the scrollbar), a current value (the top of the thumb), and an extent (the length of the thumb).
| Field Summary | |
|---|---|
static String |
PROPERTY_EXTENT
Extent property name |
static String |
PROPERTY_MAXIMUM
Maximum property name |
static String |
PROPERTY_MINIMUM
Minimum property name |
static String |
PROPERTY_VALUE
Value property name |
| Method Summary | |
|---|---|
void |
addPropertyChangeListener(PropertyChangeListener listener)
Registers listener as a PropertyChangeListener of this RangeModel. |
int |
getExtent()
Returns the extent. |
int |
getMaximum()
Returns the maximum value in the range. |
int |
getMinimum()
Returns the minimum value in the range. |
int |
getValue()
Returns the current value. |
boolean |
isEnabled()
Returns true if this RangeModel is enabled. |
void |
removePropertyChangeListener(PropertyChangeListener listener)
Removes the given listener from this RangeModel's list of PropertyChangeListeners. |
void |
setAll(int min,
int extent,
int max)
Sets min, extent, and max all at once. |
void |
setExtent(int extent)
Sets the extent. |
void |
setMaximum(int max)
Sets the maximum value of the range. |
void |
setMinimum(int min)
Sets the minimum value of the range. |
void |
setValue(int value)
Sets the current value. |
| Field Detail |
|---|
static final String PROPERTY_VALUE
static final String PROPERTY_EXTENT
static final String PROPERTY_MINIMUM
static final String PROPERTY_MAXIMUM
| Method Detail |
|---|
void addPropertyChangeListener(PropertyChangeListener listener)
value,
extent, minimum and
maximum properties.
listener - The listener to addint getExtent()
int getMaximum()
int getMinimum()
int getValue()
boolean isEnabled()
true if this RangeModel is enabled.
true if this Rangel Model is enabledvoid removePropertyChangeListener(PropertyChangeListener listener)
listener - The listener to remove
void setAll(int min,
int extent,
int max)
min - the new mininumextent - the new extentmax - the new maximumvoid setExtent(int extent)
extent - The extentvoid setMaximum(int max)
max - The maximum valuevoid setMinimum(int min)
min - The minimum valuevoid setValue(int value)
value - The current value
|
Eclipse Draw2d 3.7 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||