|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sencha.gxt.widget.core.client.selection.AbstractStoreSelectionModel<M>
M - the model type contained within the storepublic abstract class AbstractStoreSelectionModel<M>
Abstract base class for store based selection models.
| Constructor Summary | |
|---|---|
AbstractStoreSelectionModel()
|
|
| Method Summary | |
|---|---|
HandlerRegistration |
addBeforeSelectionHandler(BeforeSelectionHandler<M> handler)
|
HandlerRegistration |
addSelectionChangedHandler(SelectionChangedEvent.SelectionChangedHandler<M> handler)
Adds a SelectionChangedEvent.SelectionChangedHandler handler for
SelectionChangedEvent events. |
HandlerRegistration |
addSelectionHandler(SelectionHandler<M> handler)
|
void |
bind(Store<M> store)
Binds the store to the selection model. |
void |
deselect(int index)
Deselects the item at the given index. |
void |
deselect(int start,
int end)
Deselects the range. |
void |
deselect(java.util.List<M> items)
Deselects the items. |
void |
deselect(M... items)
Deselects the items. |
void |
deselect(M item)
Deselects the item. |
void |
deselectAll()
Deselects all selections. |
void |
fireEvent(GwtEvent<?> event)
|
M |
getSelectedItem()
Returns the selected item. |
java.util.List<M> |
getSelectedItems()
Returns the selected items. |
java.util.List<M> |
getSelection()
|
Style.SelectionMode |
getSelectionMode()
Returns the selection mode. |
boolean |
isLocked()
Returns true if the selection model is locked. |
boolean |
isSelected(M item)
Returns true if the item is selected. |
void |
refresh()
Refreshes the current selections. |
void |
select(boolean keepExisting,
M... items)
Selects the items. |
void |
select(int index,
boolean keepExisting)
Selects the item at the given index. |
void |
select(int start,
int end,
boolean keepExisting)
Selects the range. |
void |
select(java.util.List<M> items,
boolean keepExisting)
Selects the items. |
void |
select(M item,
boolean keepExisting)
Selects the item. |
void |
selectAll()
Selects all items. |
void |
setLocked(boolean locked)
True to lock the selection model. |
void |
setSelection(java.util.List<M> selection)
|
void |
setSelectionMode(Style.SelectionMode selectionMode)
Sets the selection mode. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractStoreSelectionModel()
| Method Detail |
|---|
public HandlerRegistration addBeforeSelectionHandler(BeforeSelectionHandler<M> handler)
addBeforeSelectionHandler in interface HasBeforeSelectionHandlers<M>public HandlerRegistration addSelectionChangedHandler(SelectionChangedEvent.SelectionChangedHandler<M> handler)
SelectionChangedEvent.HasSelectionChangedHandlersSelectionChangedEvent.SelectionChangedHandler handler for
SelectionChangedEvent events.
addSelectionChangedHandler in interface SelectionChangedEvent.HasSelectionChangedHandlers<M>handler - the handler
public HandlerRegistration addSelectionHandler(SelectionHandler<M> handler)
addSelectionHandler in interface HasSelectionHandlers<M>public void bind(Store<M> store)
StoreSelectionModel
bind in interface StoreSelectionModel<M>store - the bound storepublic void deselect(int index)
StoreSelectionModel
deselect in interface StoreSelectionModel<M>index - the index of the item to be deselected
public void deselect(int start,
int end)
StoreSelectionModel
deselect in interface StoreSelectionModel<M>start - the start indexend - the end indexpublic void deselect(java.util.List<M> items)
StoreSelectionModel
deselect in interface StoreSelectionModel<M>items - the itempublic void deselect(M... items)
StoreSelectionModel
deselect in interface StoreSelectionModel<M>items - the items to deselectpublic void deselect(M item)
StoreSelectionModel
deselect in interface StoreSelectionModel<M>item - the item to be deselectedpublic void deselectAll()
StoreSelectionModel
deselectAll in interface StoreSelectionModel<M>public void fireEvent(GwtEvent<?> event)
fireEvent in interface HasHandlerspublic M getSelectedItem()
StoreSelectionModel
getSelectedItem in interface StoreSelectionModel<M>public java.util.List<M> getSelectedItems()
StoreSelectionModel
getSelectedItems in interface StoreSelectionModel<M>public java.util.List<M> getSelection()
public Style.SelectionMode getSelectionMode()
StoreSelectionModel
getSelectionMode in interface StoreSelectionModel<M>public boolean isLocked()
public boolean isSelected(M item)
StoreSelectionModel
isSelected in interface StoreSelectionModel<M>item - the item
public void refresh()
StoreSelectionModel
refresh in interface StoreSelectionModel<M>
public void select(boolean keepExisting,
M... items)
StoreSelectionModel
select in interface StoreSelectionModel<M>keepExisting - true to keep existing selecteditems - the items
public void select(int index,
boolean keepExisting)
StoreSelectionModel
select in interface StoreSelectionModel<M>index - the index of the item to be selectedkeepExisting - true to keep existing selected
public void select(int start,
int end,
boolean keepExisting)
StoreSelectionModel
select in interface StoreSelectionModel<M>start - the start indexend - the end indexkeepExisting - true to keep existing selected
public void select(java.util.List<M> items,
boolean keepExisting)
StoreSelectionModel
select in interface StoreSelectionModel<M>items - the items to selectkeepExisting - true to keep existing selected
public void select(M item,
boolean keepExisting)
StoreSelectionModel
select in interface StoreSelectionModel<M>item - the itemkeepExisting - true to keep existing selectedpublic void selectAll()
StoreSelectionModel
selectAll in interface StoreSelectionModel<M>public void setLocked(boolean locked)
locked - true to lockpublic void setSelection(java.util.List<M> selection)
public void setSelectionMode(Style.SelectionMode selectionMode)
StoreSelectionModelThe selection model supports 3 different selection modes:
setSelectionMode in interface StoreSelectionModel<M>selectionMode - the selection mode
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||