Class ElementEdgeEditor

java.lang.Object
org.eclipse.core.commands.common.EventManager
org.eclipse.ui.part.WorkbenchPart
org.eclipse.ui.part.EditorPart
uk.ac.gda.richbeans.editors.RichBeanEditorPart
uk.ac.gda.exafs.ui.ElementEdgeEditor
All Implemented Interfaces:
EventListener, org.eclipse.core.runtime.IAdaptable, org.eclipse.core.runtime.IExecutableExtension, org.eclipse.richbeans.api.event.ValueListener, org.eclipse.richbeans.api.widget.IFieldProvider, org.eclipse.ui.IEditorPart, org.eclipse.ui.IReusableEditor, org.eclipse.ui.ISaveablePart, org.eclipse.ui.IWorkbenchPart, org.eclipse.ui.IWorkbenchPart2, org.eclipse.ui.IWorkbenchPart3, org.eclipse.ui.part.IWorkbenchPartOrientation
Direct Known Subclasses:
QEXAFSParametersUIEditor, XanesScanParametersUIEditor, XasScanParametersUIEditor

public abstract class ElementEdgeEditor extends RichBeanEditorPart
Class does not need to be public but is made so here so that tests can access it.
  • Field Details

    • edge

      protected org.eclipse.richbeans.widgets.wrappers.ComboWrapper edge
    • element

      protected org.eclipse.richbeans.widgets.wrappers.ComboWrapper element
    • scrolledComposite

      protected org.eclipse.swt.custom.ScrolledComposite scrolledComposite
    • container

      protected org.eclipse.swt.widgets.Composite container
    • estimatePointsLabel

      protected org.eclipse.swt.widgets.Label estimatePointsLabel
    • estimateTimeLabel

      protected org.eclipse.swt.widgets.Label estimateTimeLabel
    • expandContainer

      protected org.eclipse.swt.widgets.Composite expandContainer
    • plottingsystem

      protected IPlottingSystem<org.eclipse.swt.widgets.Composite> plottingsystem
    • plottingsystemActionBarWrapper

      protected ActionBarWrapper plottingsystemActionBarWrapper
    • xAxisValues

      protected AxisValues xAxisValues
    • suspendGraphUpdate

      protected volatile boolean suspendGraphUpdate
    • lastPlottedBean

      protected Object lastPlottedBean
    • updateValueAllowed

      protected boolean updateValueAllowed
    • plotUpdateJob

      protected uk.ac.gda.exafs.ui.ElementEdgeEditor.PlotUpdateJob plotUpdateJob
    • EXAFS_MIN_ELEMENT_PROP

      public static final String EXAFS_MIN_ELEMENT_PROP
      See Also:
    • EXAFS_MAX_ELEMENT_PROP

      public static final String EXAFS_MAX_ELEMENT_PROP
      See Also:
  • Constructor Details

  • Method Details

    • init

      public void init(org.eclipse.ui.IEditorSite site, org.eclipse.ui.IEditorInput input) throws org.eclipse.ui.PartInitException
      Specified by:
      init in interface org.eclipse.ui.IEditorPart
      Overrides:
      init in class RichBeanEditorPart
      Throws:
      org.eclipse.ui.PartInitException
    • createEstimationComposite

      protected void createEstimationComposite(org.eclipse.swt.widgets.Composite right)
      You can override this method and call it at the start of your implementation.
    • linkUI

      public void linkUI(boolean isPageChange)
      Description copied from class: RichBeanEditorPart
      Extending classes should normally override this method with bounds and choice information and then call this method with super.linkUI();
      Overrides:
      linkUI in class RichBeanEditorPart
    • getExpressionFields

      protected List<String> getExpressionFields() throws Exception
      Description copied from class: RichBeanEditorPart
      Override this method (usually by calling it too) to add values which should be available in expressions. NOTE when overriding that after the first call the expressionFields are cached to avoid too many interogations of the bean.
      Overrides:
      getExpressionFields in class RichBeanEditorPart
      Returns:
      List of possible expression vars.
      Throws:
      Exception
    • getFieldValue

      public Object getFieldValue(String fieldName) throws Exception
      Specified by:
      getFieldValue in interface org.eclipse.richbeans.api.widget.IFieldProvider
      Overrides:
      getFieldValue in class RichBeanEditorPart
      Throws:
      Exception
    • updatePlottedPoints

      public void updatePlottedPoints()
    • getLineLabels

      protected String[] getLineLabels()
      Override to provide additional lines to the edge value.
    • getLineValues

      protected double[] getLineValues()
      Override to provide additional lines to the edge value.
    • getLineColours

      protected Color[] getLineColours()
      Override to provide additional lines to the edge value.
    • updateLayout

      protected void updateLayout()
    • createElementEdgeArea

      protected void createElementEdgeArea(org.eclipse.swt.widgets.Group main)
    • setupElementAndEdge

      protected SchemaReader setupElementAndEdge(String objectName) throws Exception
      Parameters:
      objectName -
      Returns:
      SchemaReader
      Throws:
      Exception
    • setPointsUpdate

      protected void setPointsUpdate(boolean isUpdate)
    • getScanPoints

      protected double[][] getScanPoints(Object currentBean) throws Exception
      Throws:
      Exception
    • updatePointsLabels

      protected void updatePointsLabels()
    • fetchEditingBean

      protected Object fetchEditingBean()
    • updateElement

      protected void updateElement(ElementEdgeEditor.ELEMENT_EVENT_TYPE type) throws Exception
      Throws:
      Exception
    • getSelectedElement

      protected Element getSelectedElement(ElementEdgeEditor.ELEMENT_EVENT_TYPE type) throws Exception
      Throws:
      Exception
    • dispose

      public void dispose()
      Specified by:
      dispose in interface org.eclipse.ui.IWorkbenchPart
      Overrides:
      dispose in class RichBeanEditorPart
    • getElementUseBean

      protected Element getElementUseBean() throws Exception
      Throws:
      Exception
    • getEdgeUseBean

      protected String getEdgeUseBean() throws Exception
      Throws:
      Exception
    • getEdgeValue

      protected double getEdgeValue()
      Returns the edge value in eV. Uses the bean if value is not in the ui.
      Returns:
      edge
    • getCoreHole

      protected org.eclipse.richbeans.widgets.wrappers.LabelWrapper getCoreHole()
    • getEdgeEnergy

      public org.eclipse.richbeans.widgets.scalebox.ScaleBox getEdgeEnergy()
    • setFocus

      public void setFocus()
      Specified by:
      setFocus in interface org.eclipse.ui.IWorkbenchPart
      Specified by:
      setFocus in class org.eclipse.ui.part.WorkbenchPart
    • openPreferences

      protected void openPreferences()
    • getEdge

      public org.eclipse.richbeans.widgets.wrappers.ComboWrapper getEdge()
    • getElement

      public org.eclipse.richbeans.widgets.wrappers.ComboWrapper getElement()
    • getMinAllowedElementSymbol

      public String getMinAllowedElementSymbol()
    • getMaxAllowedElemenetSymbol

      public String getMaxAllowedElemenetSymbol()