T
- the type of the objects that will be selectedpublic interface ILcdSelection<T>
iterating
over the selected objects,
testing
if an object is selected,
and subscribing
to be notified of any
changes in the selection.ILcdSelectionListener
,
TLcdSelectionChangedEvent
Modifier and Type | Method and Description |
---|---|
void |
addSelectionListener(ILcdSelectionListener<T> aSelectionListener)
Adds a listener to this selection.
|
default List<T> |
getSelectedObjects()
Returns a
List of the selected objects. |
int |
getSelectionCount()
Returns the number of objects in this selection.
|
boolean |
isSelected(Object aObject)
Checks whether the given
Object is currently in the set of
selected objects. |
void |
removeSelectionListener(ILcdSelectionListener<T> aSelectionListener)
Removes an
ILcdSelectionListener from this ILcdSelection . |
Enumeration<T> |
selectedObjects()
Returns the objects in this selection.
|
int getSelectionCount()
ILcdSelection
.Enumeration<T> selectedObjects()
ILcdSelection
.boolean isSelected(Object aObject)
Object
is currently in the set of
selected objects.aObject
- the Object
to be checked.true
if the Object
is in this ILcdSelection
,
false otherwise.default List<T> getSelectedObjects()
List
of the selected objects.List
of the objects in this ILcdSelection
void addSelectionListener(ILcdSelectionListener<T> aSelectionListener)
ILcdSelection
,
you can use a ALcdWeakSelectionListener
instance as selection listener.aSelectionListener
- the ILcdSelectionListener
to be added.void removeSelectionListener(ILcdSelectionListener<T> aSelectionListener)
ILcdSelectionListener
from this ILcdSelection
.aSelectionListener
- the ILcdSelectionListener
to be removed.