Interface SelectionModel.Multi.Batched<T>
-
- Type Parameters:
T
- type parameter corresponding with Grid row type
- All Superinterfaces:
SelectionModel<T>
,SelectionModel.Multi<T>
- All Known Implementing Classes:
MultiSelectionModelConnector.MultiSelectionModel
,SelectionModelMulti
- Enclosing interface:
- SelectionModel.Multi<T>
public static interface SelectionModel.Multi.Batched<T> extends SelectionModel.Multi<T>
A multi selection model that can send selections and deselections in a batch, instead of committing them one-by-one.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.vaadin.client.widget.grid.selection.SelectionModel
SelectionModel.Multi<T>, SelectionModel.None<T>, SelectionModel.Single<T>
-
Nested classes/interfaces inherited from interface com.vaadin.client.widget.grid.selection.SelectionModel.Multi
SelectionModel.Multi.Batched<T>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
commitBatchSelect()
Commits and ends a batch selection.Collection<T>
getDeselectedRowsBatch()
Gets all the rows that would become deselected in this batch.Collection<T>
getSelectedRowsBatch()
Gets all the rows that would become selected in this batch.boolean
isBeingBatchSelected()
Checks whether or not a batch has been started.void
startBatchSelect()
Starts a batch selection.-
Methods inherited from interface com.vaadin.client.widget.grid.selection.SelectionModel
getSelectedRows, getSelectionColumnRenderer, isSelected, reset, setGrid
-
Methods inherited from interface com.vaadin.client.widget.grid.selection.SelectionModel.Multi
deselect, deselect, deselectAll, select, select
-
-
-
-
Method Detail
-
startBatchSelect
void startBatchSelect()
Starts a batch selection.Any commands to any select or deselect method will be batched into one, and a final selection event will be fired when
commitBatchSelect()
is called.Note:
SelectionChangeEvents
will still be fired for each selection/deselection. You should check whether the event is a part of a batch or not withSelectionEvent.isBatchedSelection()
.
-
commitBatchSelect
void commitBatchSelect()
Commits and ends a batch selection.Any and all selections and deselections since the last invocation of
startBatchSelect()
will be fired at once as one collatedSelectionEvent
.
-
isBeingBatchSelected
boolean isBeingBatchSelected()
Checks whether or not a batch has been started.- Returns:
true
iff a batch has been started
-
getSelectedRowsBatch
Collection<T> getSelectedRowsBatch()
Gets all the rows that would become selected in this batch.- Returns:
- a collection of the rows that would become selected
-
getDeselectedRowsBatch
Collection<T> getDeselectedRowsBatch()
Gets all the rows that would become deselected in this batch.- Returns:
- a collection of the rows that would become deselected
-
-