com.vaadin.ui.
Interface Grid.SelectionModel.Multi
-
All Superinterfaces:
ClientConnector
,Connector
,Extension
,Grid.SelectionModel
,Serializable
All Known Implementing Classes:
Enclosing interface:
public static interface Grid.SelectionModel.Multi extends Grid.SelectionModel
A SelectionModel that supports multiple selections to be made.
This interface has a contract of having the same behavior, no matter how the selection model is interacted with. In other words, if something is forbidden to do in e.g. the user interface, it must also be forbidden to do in the server-side and client-side APIs.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.vaadin.server.ClientConnector
ClientConnector.AttachEvent, ClientConnector.AttachListener, ClientConnector.ConnectorErrorEvent, ClientConnector.DetachEvent, ClientConnector.DetachListener
-
Nested classes/interfaces inherited from interface com.vaadin.ui.Grid.SelectionModel
Grid.SelectionModel.HasUserSelectionAllowed, Grid.SelectionModel.Multi, Grid.SelectionModel.None, Grid.SelectionModel.Single
-
-
Method Summary
All Methods Modifier and Type Method Description boolean
deselect(Object... itemIds)
Marks items as deselected.
boolean
deselect(Collection<?> itemIds)
Marks items as deselected.
boolean
deselectAll()
Marks all the items in the current Container as deselected
boolean
select(Object... itemIds)
Marks items as selected.
boolean
select(Collection<?> itemIds)
Marks items as selected.
boolean
selectAll()
Marks all the items in the current Container as selected
boolean
setSelected(Object... itemIds)
Marks items as selected while deselecting all items not in the varargs array.
boolean
setSelected(Collection<?> itemIds)
Marks items as selected while deselecting all items not in the given Collection.
-
Methods inherited from interface com.vaadin.server.ClientConnector
addAttachListener, addDetachListener, attach, beforeClientResponse, detach, encodeState, getErrorHandler, getExtensions, getParent, getRpcManager, getStateType, getUI, handleConnectorRequest, isAttached, isConnectorEnabled, markAsDirty, markAsDirtyRecursive, removeAttachListener, removeDetachListener, removeExtension, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandler
-
Methods inherited from interface com.vaadin.shared.Connector
getConnectorId
-
Methods inherited from interface com.vaadin.ui.Grid.SelectionModel
getSelectedRows, isSelected, reset, setGrid
-
-
-
-
Method Detail
-
select
boolean select(Object... itemIds) throws IllegalArgumentException
Marks items as selected.
This method does not clear any previous selection state, only adds to it.
Parameters:
itemIds
- the itemId(s) to mark as selectedReturns:
true
if the selection state changed.false
if all the given itemIds already were selectedThrows:
IllegalArgumentException
- if theitemIds
varargs array isnull
or given itemIds don't exist in the container of GridSee Also:
-
select
boolean select(Collection<?> itemIds) throws IllegalArgumentException
Marks items as selected.
This method does not clear any previous selection state, only adds to it.
Parameters:
itemIds
- the itemIds to mark as selectedReturns:
true
if the selection state changed.false
if all the given itemIds already were selectedThrows:
IllegalArgumentException
- ifitemIds
isnull
or given itemIds don't exist in the container of GridSee Also:
-
deselect
boolean deselect(Object... itemIds) throws IllegalArgumentException
Marks items as deselected.
Parameters:
itemIds
- the itemId(s) to remove from being selectedReturns:
true
if the selection state changed.false
if none the given itemIds were selected previouslyThrows:
IllegalArgumentException
- if theitemIds
varargs array isnull
See Also:
-
deselect
boolean deselect(Collection<?> itemIds) throws IllegalArgumentException
Marks items as deselected.
Parameters:
itemIds
- the itemId(s) to remove from being selectedReturns:
true
if the selection state changed.false
if none the given itemIds were selected previouslyThrows:
IllegalArgumentException
- ifitemIds
isnull
See Also:
-
selectAll
boolean selectAll()
Marks all the items in the current Container as selected
Returns:
true
iff some items were previously not selectedSee Also:
-
deselectAll
boolean deselectAll()
Marks all the items in the current Container as deselected
Returns:
true
iff some items were previously selectedSee Also:
-
setSelected
boolean setSelected(Collection<?> itemIds) throws IllegalArgumentException
Marks items as selected while deselecting all items not in the given Collection.
Parameters:
itemIds
- the itemIds to mark as selectedReturns:
true
if the selection state changed.false
if all the given itemIds already were selectedThrows:
IllegalArgumentException
- ifitemIds
isnull
or given itemIds don't exist in the container of Grid
-
setSelected
boolean setSelected(Object... itemIds) throws IllegalArgumentException
Marks items as selected while deselecting all items not in the varargs array.
Parameters:
itemIds
- the itemIds to mark as selectedReturns:
true
if the selection state changed.false
if all the given itemIds already were selectedThrows:
IllegalArgumentException
- if theitemIds
varargs array isnull
or given itemIds don't exist in the container of Grid
-
-