Class PlotDataEditor

java.lang.Object
org.eclipse.core.commands.common.EventManager
org.eclipse.ui.part.WorkbenchPart
org.eclipse.ui.part.EditorPart
org.dawb.workbench.ui.editors.PlotDataEditor
All Implemented Interfaces:
ITitledEditor, org.eclipse.core.runtime.IAdaptable, org.eclipse.core.runtime.IExecutableExtension, ISelectedPlotting, ISlicablePlottingPart, 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

public class PlotDataEditor extends org.eclipse.ui.part.EditorPart implements org.eclipse.ui.IReusableEditor, ISlicablePlottingPart, ITitledEditor, ISelectedPlotting
An editor which combines a plot with a graph of data sets.
  • Field Summary

    Fields inherited from interface org.eclipse.ui.IEditorPart

    PROP_DIRTY, PROP_INPUT

    Fields inherited from interface org.eclipse.ui.IWorkbenchPart

    PROP_TITLE
  • Constructor Summary

    Constructors
    Constructor
    Description
    PlotDataEditor(PlotType defaultPlotType)
     
    PlotDataEditor(PlotType defaultPlotType, ITitledEditor parent)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    createPartControl(org.eclipse.swt.widgets.Composite parent)
     
    protected List<ITrace>
    createPlotSeparateAxes(org.eclipse.january.dataset.IDataset x, Map<Integer,List<org.eclipse.january.dataset.IDataset>> ysMap, Map<Integer,List<String>> dNameMap, org.eclipse.core.runtime.IProgressMonitor monitor)
     
    void
    Call to change plot default by looking at data
    void
     
    void
    doSave(org.eclipse.core.runtime.IProgressMonitor monitor)
     
    void
     
     
    protected void
    getAxisSettings(String propertyStub, IAxis axis)
     
     
    IPlottingSystem<org.eclipse.swt.widgets.Composite>
     
    IPlottingSystem<org.eclipse.swt.widgets.Composite>
     
    Map<String,org.eclipse.january.dataset.IDataset>
     
     
    void
    init(org.eclipse.ui.IEditorSite site, org.eclipse.ui.IEditorInput input)
     
    boolean
     
    boolean
     
    void
    setAll1DSelected(boolean overide)
    Method used to select all 1D plots in the order they are extracted.
    protected void
    setAxisSettings(String propertyStub, IAxis axis)
     
    void
     
    void
    setInput(org.eclipse.ui.IEditorInput input)
     
    void
     
    void
    setToolbarsVisible(boolean isVisible)
     
     
    void
    updatePlot(ITransferableDataObject[] selections, ISliceSystem sliceSystem, boolean useTask)
    Must be called in UI thread

    Methods inherited from class org.eclipse.ui.part.EditorPart

    checkSite, getEditorInput, getEditorSite, getTitleToolTip, isSaveOnCloseNeeded, setContentDescription, setInitializationData, setInputWithNotify, setPartName

    Methods inherited from class org.eclipse.ui.part.WorkbenchPart

    addPartPropertyListener, addPropertyListener, firePartPropertyChanged, firePropertyChange, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy

    Methods inherited from class org.eclipse.core.commands.common.EventManager

    addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.eclipse.ui.IEditorPart

    getEditorInput, getEditorSite

    Methods inherited from interface org.eclipse.ui.ISaveablePart

    isSaveOnCloseNeeded

    Methods inherited from interface org.eclipse.ui.IWorkbenchPart

    addPropertyListener, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener
  • Constructor Details

    • PlotDataEditor

      public PlotDataEditor(PlotType defaultPlotType)
    • PlotDataEditor

      public PlotDataEditor(PlotType defaultPlotType, ITitledEditor parent)
  • 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
      Specified by:
      init in class org.eclipse.ui.part.EditorPart
      Throws:
      org.eclipse.ui.PartInitException
    • getSelected

      public Map<String,org.eclipse.january.dataset.IDataset> getSelected()
      Specified by:
      getSelected in interface ISelectedPlotting
    • isDirty

      public boolean isDirty()
      Specified by:
      isDirty in interface org.eclipse.ui.ISaveablePart
      Specified by:
      isDirty in class org.eclipse.ui.part.EditorPart
    • setToolbarsVisible

      public void setToolbarsVisible(boolean isVisible)
    • createPartControl

      public void createPartControl(org.eclipse.swt.widgets.Composite parent)
      Specified by:
      createPartControl in interface org.eclipse.ui.IWorkbenchPart
      Specified by:
      createPartControl in class org.eclipse.ui.part.WorkbenchPart
    • setAxisSettings

      protected void setAxisSettings(String propertyStub, IAxis axis)
    • getAxisSettings

      protected void getAxisSettings(String propertyStub, IAxis axis)
    • createPlotTypeDefaultFromData

      public void createPlotTypeDefaultFromData()
      Call to change plot default by looking at data
    • updatePlot

      public void updatePlot(ITransferableDataObject[] selections, ISliceSystem sliceSystem, boolean useTask)
      Must be called in UI thread
      Specified by:
      updatePlot in interface ISlicablePlottingPart
      Parameters:
      selections -
      useTask -
    • createPlotSeparateAxes

      protected List<ITrace> createPlotSeparateAxes(org.eclipse.january.dataset.IDataset x, Map<Integer,List<org.eclipse.january.dataset.IDataset>> ysMap, Map<Integer,List<String>> dNameMap, org.eclipse.core.runtime.IProgressMonitor monitor)
    • setInput

      public void setInput(org.eclipse.ui.IEditorInput input)
      Specified by:
      setInput in interface org.eclipse.ui.IReusableEditor
      Overrides:
      setInput in class org.eclipse.ui.part.EditorPart
    • setAll1DSelected

      public void setAll1DSelected(boolean overide)
      Method used to select all 1D plots in the order they are extracted. If overide then current selected plots will be ignored.
    • setFocus

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

      public void doSave(org.eclipse.core.runtime.IProgressMonitor monitor)
      Specified by:
      doSave in interface org.eclipse.ui.ISaveablePart
      Specified by:
      doSave in class org.eclipse.ui.part.EditorPart
    • doSaveAs

      public void doSaveAs()
      Specified by:
      doSaveAs in interface org.eclipse.ui.ISaveablePart
      Specified by:
      doSaveAs in class org.eclipse.ui.part.EditorPart
    • isSaveAsAllowed

      public boolean isSaveAsAllowed()
      Specified by:
      isSaveAsAllowed in interface org.eclipse.ui.ISaveablePart
      Specified by:
      isSaveAsAllowed in class org.eclipse.ui.part.EditorPart
    • dispose

      public void dispose()
      Specified by:
      dispose in interface org.eclipse.ui.IWorkbenchPart
      Overrides:
      dispose in class org.eclipse.ui.part.WorkbenchPart
    • getDataSetComponent

      public IVariableManager getDataSetComponent()
    • getSliceComponent

      public ISliceSystem getSliceComponent()
    • getPlotWindow

      public IPlottingSystem<org.eclipse.swt.widgets.Composite> getPlotWindow()
    • getPlottingSystem

      public IPlottingSystem<org.eclipse.swt.widgets.Composite> getPlottingSystem()
    • getAdapter

      public Object getAdapter(Class clazz)
      Specified by:
      getAdapter in interface org.eclipse.core.runtime.IAdaptable
      Overrides:
      getAdapter in class org.eclipse.ui.part.WorkbenchPart
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • setPartTitle

      public void setPartTitle(String name)
      Specified by:
      setPartTitle in interface ITitledEditor