Interface OptionsField<V,I>

Type Parameters:
V - type of value
I - type of option items
All Superinterfaces:
Component, Component.BelongToFrame, Component.Editable, Component.HasCaption, Component.HasDescription, Component.HasIcon, Field<V>, HasContextHelp, HasHtmlCaption, HasHtmlDescription, HasHtmlSanitizer, HasOptionCaptionProvider<I>, HasValidator<V>, HasValue<V>, HasValueSource<V>, Requirable, Validatable
All Known Subinterfaces:
CheckBoxGroup<I>, ComboBox<V>, EntityComboBox<V>, MultiSelectList<V>, RadioButtonGroup<I>, SelectList<V,I>, SingleSelectList<V>, TagPicker<V>, TwinColumn<V>
All Known Implementing Classes:
AbstractSelectList, CheckBoxGroupImpl, ComboBoxImpl, EntityComboBoxImpl, MultiSelectListImpl, RadioButtonGroupImpl, SingleSelectListImpl, TagPickerImpl, TwinColumnImpl

public interface OptionsField<V,I> extends Field<V>, HasOptionCaptionProvider<I>
UI component having options.
  • Method Details

    • setOptions

      void setOptions(@Nullable Options<I> options)
      Sets options for UI component.
      Parameters:
      options - options
      See Also:
    • getOptions

      @Nullable Options<I> getOptions()
      Returns:
      options object
    • setOptionsList

      default void setOptionsList(List<I> optionsList)
      Sets options from the passed list.
      Parameters:
      optionsList - options
      See Also:
    • setOptionsMap

      default void setOptionsMap(Map<String,I> map)
      Sets options from the passed map and automatically applies option caption provider based on map keys.
      Parameters:
      map - options
      See Also:
    • setOptionsEnum

      default void setOptionsEnum(Class<I> optionsEnum)
      Sets options from the passed enum class. Enum class must be Java enumeration and implement EnumClass.
      Parameters:
      optionsEnum - enum class