Class AbstractBoolEditPart

java.lang.Object
org.eclipse.gef.editparts.AbstractEditPart
org.eclipse.gef.editparts.AbstractGraphicalEditPart
All Implemented Interfaces:
IPVWidgetEditpart, IAdaptable, org.eclipse.gef.EditPart, org.eclipse.gef.GraphicalEditPart, org.eclipse.gef.NodeEditPart, org.eclipse.gef.RequestConstants
Direct Known Subclasses:
AbstractBoolControlEditPart, ImageBoolIndicatorEditPart, LEDEditPart

public abstract class AbstractBoolEditPart extends AbstractPVWidgetEditPart
Base editPart controller for a widget based on AbstractBoolWidgetModel.
  • Constructor Details

    • AbstractBoolEditPart

      public AbstractBoolEditPart()
  • Method Details

    • initializeCommonFigureProperties

      protected void initializeCommonFigureProperties(AbstractBoolFigure figure, AbstractBoolWidgetModel model)
      Sets those properties on the figure that are defined in the AbstractBoolFigure base class. This method is provided for the convenience of subclasses, which can call this method in their implementation of AbstractBaseEditPart.doCreateFigure().
      Parameters:
      figure - the figure.
      model - the model.
    • getWidgetModel

      public AbstractBoolWidgetModel getWidgetModel()
      Overrides:
      getWidgetModel in class AbstractBaseEditPart
    • registerCommonPropertyChangeHandlers

      protected void registerCommonPropertyChangeHandlers()
      Registers property change handlers for the properties defined in AbstractBoolWidgetModel. This method is provided for the convenience of subclasses, which can call this method in their implementation of AbstractBaseEditPart.registerPropertyChangeHandlers().
    • setValue

      public void setValue(Object value)
      Description copied from class: AbstractBaseEditPart
      Set the value of the widget. This only takes effect on the visual presentation of the widget and will not write the value to the PV attached to this widget. Since setting value to a widget usually results in figure repaint, this method should be called in UI thread. To call it in non-UI thread, see AbstractBaseEditPart.setValueInUIThread(Object).
      Overrides:
      setValue in class AbstractBaseEditPart
      Parameters:
      value - the value to be set. It must be the compatible type for the widget. For example, a boolean widget only accept boolean or number.
    • getValue

      public Boolean getValue()
      Description copied from class: AbstractBaseEditPart
      The value of the widget that is in representing. It is not the value of the attached PV even though they are equals in most cases. The value type is specified by the widget, for example, boolean for boolean widget, double for meter and gauge.
      Overrides:
      getValue in class AbstractBaseEditPart
      Returns:
      The value of the widget.