T - the data type of the selection modelpublic interface SelectionEvent<T> extends Serializable
| Modifier and Type | Method and Description |
|---|---|
Set<T> |
getAllSelectedItems()
Gets all the currently selected items.
|
Optional<T> |
getFirstSelectedItem()
Get first selected data item.
|
boolean |
isUserOriginated()
Returns whether this selection event was triggered by user interaction,
on the client side, or programmatically, on the server side.
|
Optional<T> getFirstSelectedItem()
This is the same as SingleSelectionEvent.getSelectedItem() in
case of single selection and the first selected item from
MultiSelectionEvent.getNewSelection() in case of multi selection.
Set<T> getAllSelectedItems()
This method applies more to multiselection - for single select it returns either an empty set or a set containing the only selected item.
nullboolean isUserOriginated()
true if this event originates from the client,
false otherwise.Copyright © 2017 Vaadin Ltd. All rights reserved.