ListModel however there are some important differences:
A SpinnerModel has three properties, only the first is read/write.
value
nextValue
value is the
last element of the sequence.
previousValue
value is the
first element of the sequence.
value property changes,
ChangeListeners are notified. SpinnerModel may
choose to notify the ChangeListeners under other circumstances.
JSpinner, AbstractSpinnerModel, SpinnerListModel, SpinnerNumberModel, SpinnerDateModel
| Modifier and Type | Method and Description |
|---|---|
| public void | addChangeListener(ChangeListener
the ChangeListener to add l)Adds a |
| public Object | Returns: the next legal value or null if one doesn't existReturn the object in the sequence that comes after the object returned
by |
| public Object | Returns: the previous legal value or null if one doesn't existReturn the object in the sequence that comes before the object returned
by |
| public Object | |
| public void | removeChangeListener(ChangeListener
the ChangeListener to remove l)Removes a |
| public void |
| addChangeListener | back to summary |
|---|---|
| public void addChangeListener(ChangeListener l) Adds a
| |
| getNextValue | back to summary |
|---|---|
| public Object getNextValue() Return the object in the sequence that comes after the object returned
by
| |
| getPreviousValue | back to summary |
|---|---|
| public Object getPreviousValue() Return the object in the sequence that comes before the object returned
by
| |
| getValue | back to summary |
|---|---|
| public Object getValue() The current element of the sequence. This element is usually
displayed by the | |
| removeChangeListener | back to summary |
|---|---|
| public void removeChangeListener(ChangeListener l) Removes a
| |
| setValue | back to summary |
|---|---|
| public void setValue(Object value) Changes current value of the model, typically this value is displayed
by the
| |