Class AbstractChoiceModel

All Implemented Interfaces:
IPVWidgetModel, IAdaptable, IPropertySource
Direct Known Subclasses:
ChoiceButtonModel, RadioBoxModel

public abstract class AbstractChoiceModel extends AbstractPVWidgetModel
The abstract model for choice widget.
  • Field Details

    • PROP_ITEMS

      public static final String PROP_ITEMS
      Items of the choice widget.
      See Also:
    • PROP_ITEMS_FROM_PV

      public static final String PROP_ITEMS_FROM_PV
      If this is true, items will be loaded from input Enum PV.
      See Also:
    • PROP_SELECTED_COLOR

      public static final String PROP_SELECTED_COLOR
      The color of the selected item.
      See Also:
    • DEFAULT_SELECTED_COLOR

      public static final RGB DEFAULT_SELECTED_COLOR
    • PROP_HORIZONTAL

      public static final String PROP_HORIZONTAL
      True if items should be horizontal arranged.
      See Also:
    • DEFAULT_ITEMS

      public static final String[] DEFAULT_ITEMS
  • Constructor Details

    • AbstractChoiceModel

      public AbstractChoiceModel()
  • Method Details

    • configureProperties

      protected void configureProperties()
      Description copied from class: AbstractWidgetModel
      Configure the properties of the widget. Subclass should add new properties in this method.
      Specified by:
      configureProperties in class AbstractWidgetModel
    • getItems

      public List<String> getItems()
    • isItemsFromPV

      public boolean isItemsFromPV()
    • getSelectedColor

      public OPIColor getSelectedColor()
    • isHorizontal

      public boolean isHorizontal()
      Returns:
      true if the widget is in horizontal orientation, false otherwise