com.holonplatform.vaadin.components.builders

## Interface BaseSelectModeSingleSelectInputBuilder<T,B extends BaseSelectModeSingleSelectInputBuilder<T,B>>

- Type Parameters:
    `T` - Value type
    `B` - Actual builder type
  All Superinterfaces:
    BaseSelectInputBuilder<T,SingleSelect<T>,T,T,B>, BaseSelectInputBuilder.SingleSelectConfigurator<T,T,B>, ComponentConfigurator<B>, InputBuilder<T,SingleSelect<T>,B>, InputConfigurator<T,B>, SelectInputBuilder<T,SingleSelect<T>,T,T,B>, SelectItemDataSourceBuilder<T,SingleSelect<T>,T,T,B>, SingleSelectInputBuilder<T,B>
  All Known Subinterfaces:
    BaseSelectModeSingleSelectInputBuilder.NativeModeSingleSelectInputBuilder<T>, BaseSelectModeSingleSelectInputBuilder.SelectModeSingleSelectInputBuilder<T>

      public interface BaseSelectModeSingleSelectInputBuilder<T,B extends BaseSelectModeSingleSelectInputBuilder<T,B>>
      extends SingleSelectInputBuilder<T,B>

  A `SingleSelectInputBuilder` for `RenderingMode#NATIVE_SELECT` and `RenderingMode#SELECT`.
  Since:
    5.0.0

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static interface` | `BaseSelectModeSingleSelectInputBuilder.NativeModeSingleSelectInputBuilder<T>` A `SingleSelectInputBuilder` for `RenderingMode#NATIVE_SELECT`.
    `static interface` | `BaseSelectModeSingleSelectInputBuilder.OptionsModeSingleSelectInputBuilder<T>` A `SingleSelectInputBuilder` for `RenderingMode#OPTIONS`.
    `static interface` | `BaseSelectModeSingleSelectInputBuilder.SelectModeSingleSelectInputBuilder<T>` A `SingleSelectInputBuilder` for `RenderingMode#SELECT`.

    - ### Nested classes/interfaces inherited from interface com.holonplatform.vaadin.components.builders.SingleSelectInputBuilder

      `SingleSelectInputBuilder.GenericSingleSelectInputBuilder<T>`

    - ### Nested classes/interfaces inherited from interface com.holonplatform.vaadin.components.builders.BaseSelectInputBuilder

      `BaseSelectInputBuilder.MultiSelectConfigurator<T,ITEM,B extends BaseSelectInputBuilder.MultiSelectConfigurator<T,ITEM,B>>, BaseSelectInputBuilder.RenderingMode, BaseSelectInputBuilder.SingleSelectConfigurator<T,ITEM,B extends BaseSelectInputBuilder.SingleSelectConfigurator<T,ITEM,B>>`

    - ### Nested classes/interfaces inherited from interface com.holonplatform.vaadin.components.builders.InputConfigurator

      `InputConfigurator.BaseFieldConfigurator<T>`

    - ### Nested classes/interfaces inherited from interface com.holonplatform.vaadin.components.builders.ComponentConfigurator

      `ComponentConfigurator.BaseComponentConfigurator`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `B` | `emptySelectionAllowed(boolean emptySelectionAllowed)` Sets whether the user is allowed to select nothing.
    `B` | `emptySelectionCaption(com.holonplatform.core.i18n.Localizable caption)` Sets the empty selection caption.
    `default B` | `emptySelectionCaption(String caption)` Sets the empty selection caption.
    `default B` | `emptySelectionCaption(String defaultCaption, String messageCode, Object... arguments)` Sets the empty selection caption using a localizable `messageCode`.

    - ### Methods inherited from interface com.holonplatform.vaadin.components.builders.SingleSelectInputBuilder

      `dataSource, dataSource`

    - ### Methods inherited from interface com.holonplatform.vaadin.components.builders.SelectItemDataSourceBuilder

      `dataSource, dataSource`

    - ### Methods inherited from interface com.holonplatform.vaadin.components.builders.SelectInputBuilder

      `addItem, addItem, addItem, addItem, items, items`

    - ### Methods inherited from interface com.holonplatform.vaadin.components.builders.BaseSelectInputBuilder

      `itemCaption, itemCaption, itemCaption, itemCaptionGenerator, itemDescriptionGenerator, itemIcon, itemIconGenerator`

    - ### Methods inherited from interface com.holonplatform.vaadin.components.builders.InputBuilder

      `asField, build, deferLocalization, dragSource, dropTarget, validatable`

    - ### Methods inherited from interface com.holonplatform.vaadin.components.builders.InputConfigurator

      `locale, readOnly, tabIndex, withValue, withValueChangeListener`

    - ### Methods inherited from interface com.holonplatform.vaadin.components.builders.ComponentConfigurator

      `caption, caption, caption, captionAsHtml, description, description, description, disabled, errorHandler, fullHeight, fullSize, fullWidth, height, height, heightUndefined, hidden, icon, id, notVisible, primaryStyleName, replaceStyleName, responsive, sizeUndefined, styleName, width, width, widthUndefined, withAttachListener, withContextClickListener, withData, withDetachListener, withShortcutListener`

- - ### Method Detail

    - #### emptySelectionAllowed

          B emptySelectionAllowed(boolean emptySelectionAllowed)

      Sets whether the user is allowed to select nothing. When true, a special empty item is shown to the user.
      Parameters:
        `emptySelectionAllowed` - true to allow not selecting anything, false to require selection
      Returns:
        this

    - #### emptySelectionCaption

          default B emptySelectionCaption(String caption)

      Sets the empty selection caption.
      Parameters:
        `caption` - the empty selection caption to set, `null` for none
      Returns:
        this

    - #### emptySelectionCaption

          default B emptySelectionCaption(String defaultCaption,
                                          String messageCode,
                                          Object... arguments)

      Sets the empty selection caption using a localizable `messageCode`.

      For caption localization, a `LocalizationContext` must be available and localized as `Context` resource when component is built or when component is displayed if `InputBuilder.deferLocalization()` is `true`.

      Parameters:
        `defaultCaption` - Default message if no translation is available for given `messageCode` for current Locale.
        `messageCode` - the empty selection caption translation message key
        `arguments` - Optional translation arguments
      Returns:
        this

    - #### emptySelectionCaption

          B emptySelectionCaption(com.holonplatform.core.i18n.Localizable caption)

      Sets the empty selection caption.

      For caption localization, a `LocalizationContext` must be available and localized as `Context` resource when component is built or when component is displayed if `InputBuilder.deferLocalization()` is `true`.

      Parameters:
        `caption` - Localizable empty selection caption
      Returns:
        this

Copyright © 2019 The Holon Platform. All rights reserved.