|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Selectable<E>
Indicate a selectable collection or component. Generally used with ListModel
and Listbox
.
ListModel
,
Listbox
Method Summary | |
---|---|
boolean |
addToSelection(E obj)
Add the specified object into selection. |
void |
clearSelection()
Change the selection to the empty set. |
java.util.Set<E> |
getSelection()
Returns the current selection. |
boolean |
isMultiple()
Returns whether the current selection mode is multiple. |
boolean |
isSelected(java.lang.Object obj)
Returns whether an object is selected. |
boolean |
isSelectionEmpty()
Returns true if the selection is currently empty. |
boolean |
removeFromSelection(java.lang.Object obj)
Remove the specified object from selection. |
void |
setMultiple(boolean multiple)
Sets the selection mode to be multiple. |
void |
setSelection(java.util.Collection<? extends E> selection)
Replace the current selection with the given set. |
Method Detail |
---|
java.util.Set<E> getSelection()
void setSelection(java.util.Collection<? extends E> selection)
If this represents a change to the current selection then notify each ListDataListener, including UI.
boolean isSelected(java.lang.Object obj)
boolean isSelectionEmpty()
boolean addToSelection(E obj)
If this represents a change to the current selection then notify each ListDataListener, including UI.
obj
- the object to be as selection.
obj
is not part of the data, or was already selected.boolean removeFromSelection(java.lang.Object obj)
If this represents a change to the current selection then notify each ListDataListener, including UI.
obj
- the object to be remove from selection.
void clearSelection()
If this represents a change to the current selection then notify each ListDataListener, including UI.
void setMultiple(boolean multiple)
boolean isMultiple()
setMultiple(boolean)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |