THIS
- Self-referential generic THISITEM
- the item object type in the listingpublic interface FluentNativeSelect<THIS extends FluentNativeSelect<THIS,ITEM>,ITEM> extends FluentAbstractSingleSelect<THIS,ITEM>, FluentFieldEvents.FluentFocusNotifier<THIS>, FluentFieldEvents.FluentBlurNotifier<THIS>, FluentHasDataProvider<THIS,ITEM>
NativeSelect
NativeSelect
FluentComponent.FluentFocusable<C extends FluentComponent.FluentFocusable<C>>
com.vaadin.ui.Component.ErrorEvent, com.vaadin.ui.Component.Event, com.vaadin.ui.Component.Focusable, com.vaadin.ui.Component.Listener
com.vaadin.server.ClientConnector.AttachEvent, com.vaadin.server.ClientConnector.AttachListener, com.vaadin.server.ClientConnector.ConnectorErrorEvent, com.vaadin.server.ClientConnector.DetachEvent, com.vaadin.server.ClientConnector.DetachListener
Modifier and Type | Method and Description |
---|---|
default THIS |
withEmptySelectionAllowed(boolean emptySelectionAllowed)
Sets whether the user is allowed to select nothing in the combo box.
|
default THIS |
withEmptySelectionCaption(String caption)
Sets the empty selection caption.
|
default THIS |
withItemCaptionGenerator(com.vaadin.ui.ItemCaptionGenerator<ITEM> itemCaptionGenerator)
Sets the item caption generator that is used to produce the strings shown
in the combo box for each item.
|
default THIS |
withVisibleItemCount(int visibleItemCount)
Sets the number of items that are visible.
|
withSelectedItem, withSelectionListener, withValueChangeListener
withCaption, withCaptionAsHtml, withComponentError, withData, withDescription, withDescription, withLocale, withResponsive, withShortcutListener, withStyleName
withAttachListener, withDetachListener
withContextClickListener
addContextClickListener, removeContextClickListener
withItems, withItems, withItems
getDataProvider, setItems, setItems, setItems
withTabIndex
withCaption, withEnabled, withIcon, withId, withParent, withPrimaryStyleName, withStyleName, withStyleName, withVisible
addListener, addStyleName, addStyleNames, attach, getCaption, getDescription, getIcon, getId, getLocale, getParent, getPrimaryStyleName, getStyleName, getUI, isEnabled, isVisible, readDesign, removeListener, removeStyleName, removeStyleNames, setCaption, setEnabled, setIcon, setId, setParent, setPrimaryStyleName, setStyleName, setVisible, writeDesign
addAttachListener, addDetachListener, beforeClientResponse, detach, encodeState, getErrorHandler, getExtensions, getRpcManager, getStateType, handleConnectorRequest, isAttached, isConnectorEnabled, markAsDirty, markAsDirtyRecursive, removeAttachListener, removeDetachListener, removeExtension, requestRepaint, requestRepaintAll, retrievePendingRpcCalls, setErrorHandler
withFullHeight, withFullSize, withFullWidth, withHeight, withHeight, withSize, withUndefinedHeight, withUndefinedSize, withUndefinedWidth, withWidth, withWidth
getHeight, getHeightUnits, getWidth, getWidthUnits, setHeight, setHeight, setHeightUndefined, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthUndefined
withReadOnly, withRequiredIndicatorVisible, withValue
addValueChangeListener, clear, getDefaultValidator, getEmptyValue, getOptionalValue, getValue, isEmpty, isReadOnly, isRequiredIndicatorVisible, setReadOnly, setRequiredIndicatorVisible, setValue
withFocusListener
withBlurListener
withDataProvider, withItems
default THIS withItemCaptionGenerator(com.vaadin.ui.ItemCaptionGenerator<ITEM> itemCaptionGenerator)
String.valueOf(Object)
is used.itemCaptionGenerator
- the item caption provider to use, not nullNativeSelect.setItemCaptionGenerator(ItemCaptionGenerator)
default THIS withVisibleItemCount(int visibleItemCount)
visibleItemCount
- the visible item countIllegalArgumentException
- if the value is smaller than oneNativeSelect.setVisibleItemCount(int)
default THIS withEmptySelectionAllowed(boolean emptySelectionAllowed)
emptySelectionAllowed
- true to allow not selecting anything, false to require
selectionNativeSelect.setEmptySelectionAllowed(boolean)
default THIS withEmptySelectionCaption(String caption)
The empty string ""
is the default empty selection caption.
If empty selection is allowed via the
NativeSelect.setEmptySelectionAllowed(boolean)
method (it is by default) then
the empty item will be shown with the given caption.
caption
- the caption to set, not null
NativeSelect.setEmptySelectionCaption(String)
,
AbstractSingleSelect.isSelected(Object)
Copyright © 2017 Jean-Christophe Fortier. All rights reserved.