public class MultipleSelect extends SelectBase<List<String>>
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabledIndexedPanel.ForIsWidgetHasWidgets.ForIsWidgetattrMixin, itemMap, options, selectElementDEBUG_ID_PREFIXCHANGED_EVENT, HIDDEN_EVENT, HIDE_EVENT, LOADED_EVENT, REFRESHED_EVENT, RENDERED_EVENT, SHOW_EVENT, SHOWN_EVENT| Constructor and Description |
|---|
MultipleSelect() |
| Modifier and Type | Method and Description |
|---|---|
void |
deselectAll()
Deselect all items in a multi-select.
|
List<Option> |
getSelectedItems()
Returns the selected items list.
|
List<String> |
getValue() |
boolean |
isMultiple()
Returns
true if multiple selection is allowed. |
void |
selectAll()
Select all items in a multi-select.
|
void |
setCountSelectedTextFormat(int minCount)
Specifies the minimum count of the
count > # selection
format with a multiple select. |
void |
setDeselectAllText(String deselectAllText)
The text on the button that deselects all options when
actionsBox> is enabled.
Defaults to Deselect All. |
void |
setMaxOptions(int maxOptions)
When set to a positive value and in a multi-select, the
number of selected options cannot exceed the given value.
|
void |
setMaxOptionsTextHandler(MaxOptionsTextHandler handler)
Sets the handler to get texts displayed when
SelectOptions.MAX_OPTIONS
is enabled and the maximum number of options within the entire select or an
option group have been selected. |
void |
setMultipleSeparator(String multipleSeparator)
Sets the character displayed in the button that separates
selected options.
Defaults to , . |
void |
setNoneSelectedText(String noneSelectedText)
Sets the text that is displayed when a multiple select
has no selected options.
Defaults to Nothing Selected. |
void |
setSelectAllText(String selectAllText)
The text on the button that selects all options when
actionsBox> is enabled.
Defaults to Select All. |
void |
setSelectedTextFormat(SelectedTextFormat format)
Specifies how the selection is displayed with a multiple select.
Defaults to SelectedTextFormat.VALUES. |
protected void |
setSelectedValue(List<String> value)
Selects the given value.
|
void |
setShowActionsBox(boolean showActionsBox)
When set to
true, adds two buttons to the top of
the drop-down menu (Select All & Deselect All).Defaults to false. |
add, addHiddenHandler, addHideHandler, addLoadedHandler, addRefreshedHandler, addRenderedHandler, addShowHandler, addShownHandler, addValueChangeHandler, asEditor, command, getItem, getItemCount, getItems, getLanguage, getSize, getStyle, getTabIndex, getType, hide, insert, isEnabled, isItemSelected, isVisible, mobile, onLoad, onUnload, refresh, remove, render, setAccessKey, setContainer, setCountSelectedTextHandler, setDropdownAlignRight, setDropupAuto, setEnabled, setFixedMenuSize, setFocus, setForceDropup, setHeader, setHideDisabled, setLanguage, setLiveSearch, setLiveSearchNormalize, setLiveSearchPlaceholder, setLiveSearchStyle, setMenuSize, setMobile, setPlaceholder, setSelectOnTab, setSelectWidth, setShowContent, setShowIcon, setShowMenuArrow, setShowSubtext, setSize, setStyle, setTabIndex, setType, setValue, setValue, setVisible, setWidth, setWindowPadding, setWindowPaddingTopRightBottomLeft, show, togglegetId, getPull, insert, setColor, setHiddenOn, setId, setMarginBottom, setMarginLeft, setMarginRight, setMarginTop, setPaddingBottom, setPaddingLeft, setPaddingRight, setPaddingTop, setPull, setVisibleOnadd, add, adjustIndex, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, getChildren, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, insert, iterator, removeadd, adopt, clear, doAttachChildren, doDetachChildren, orphan, removeaddAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, removeFromParent, setLayoutData, sinkEvents, unsinkEventsaddStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, sinkBitlessEvent, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitfireEventforEach, spliteratorpublic MultipleSelect()
public final boolean isMultiple()
SelectBasetrue if multiple selection is allowed.isMultiple in class SelectBase<List<String>>true if multiple selection is allowedpublic void setShowActionsBox(boolean showActionsBox)
true, adds two buttons to the top of
the drop-down menu (Select All & Deselect All).false.showActionsBox - public void setDeselectAllText(String deselectAllText)
Deselect All.deselectAllText - public void setSelectAllText(String selectAllText)
Select All.selectAllText - public void setMaxOptions(int maxOptions)
maxOptions - public void setMaxOptionsTextHandler(MaxOptionsTextHandler handler)
SelectOptions.MAX_OPTIONS
is enabled and the maximum number of options within the entire select or an
option group have been selected.handler - setMaxOptions(int)public void setMultipleSeparator(String multipleSeparator)
, .multipleSeparator - public void setNoneSelectedText(String noneSelectedText)
Nothing Selected.noneSelectedText - public void setSelectedTextFormat(SelectedTextFormat format)
SelectedTextFormat.VALUES.format - SelectedTextFormatpublic void setCountSelectedTextFormat(int minCount)
count > # selection
format with a multiple select.minCount - SelectedTextFormat.getFormat(int)protected void setSelectedValue(List<String> value)
SelectBasenull
or does not match any option, no option will be selected.setSelectedValue in class SelectBase<List<String>>public List<Option> getSelectedItems()
public void selectAll()
public void deselectAll()
Copyright © 2017. All rights reserved.