All Packages Class Hierarchy This Package Previous Next Index
Interface java.awt.swing.SingleSelectionModel
- public interface SingleSelectionModel
A model that supports at most one indexed selection.
addChangeListener(ChangeListener)
- Adds listener as a listener to changes in the model.
clearSelection()
- Clears the selection (to -1).
getSelectedIndex()
-
isSelected()
- Returns true if the selection model currently has a selected value.
removeChangeListener(ChangeListener)
- Removes listener as a listener to changes in the model.
setSelectedIndex(int)
- Sets the model's selected index to index.
getSelectedIndex
public abstract int getSelectedIndex()
- Returns:
- the model's selection, or -1 if there is no selection.
- See Also:
- setSelectedIndex
setSelectedIndex
public abstract void setSelectedIndex(int index)
- Sets the model's selected index to index.
Notifies any listeners if the model changes
- See Also:
- getSelectedIndex, addChangeListener
clearSelection
public abstract void clearSelection()
- Clears the selection (to -1).
isSelected
public abstract boolean isSelected()
- Returns true if the selection model currently has a selected value.
addChangeListener
public abstract void addChangeListener(ChangeListener listener)
- Adds listener as a listener to changes in the model.
removeChangeListener
public abstract void removeChangeListener(ChangeListener listener)
- Removes listener as a listener to changes in the model.
All Packages Class Hierarchy This Package Previous Next Index
Submit a bug or feature