Interface IDiagramContainer

All Known Subinterfaces:
IDiagramContainerUI
All Known Implementing Classes:
DiagramComposite, DiagramEditor, DiagramEditorDummy

public interface IDiagramContainer
The Interface IDiagramContainer. This is the base interface for all containers that can display diagrams. Such a container may be an editor or a view, possibly also a plain composite used within e.g. a popup or inside an editor or view.
Since:
0.10
  • Method Details

    • selectPictogramElements

      void selectPictogramElements(PictogramElement[] pictogramElements)
      Selects all the given pictogram elements in the container.
      Parameters:
      pictogramElements - The pictogram elements to select
    • getSelectedPictogramElements

      PictogramElement[] getSelectedPictogramElements()
      Gets all pictogram elements that are currently selected.
      Returns:
      all selected pictogram elements
    • setPictogramElementForSelection

      void setPictogramElementForSelection(PictogramElement pictogramElement)
      Sets the pictogram element which should be selected after the container refresh.
      Parameters:
      pictogramElement - The pictogram element to select
    • setPictogramElementsForSelection

      void setPictogramElementsForSelection(PictogramElement[] pictogramElements)
      Sets the pictogram elements which should be selected after the container refresh.
      Parameters:
      pictogramElements - The pictogram elements to select
    • getTitle

      String getTitle()
      Gets the title for the container that is displaying the diagram.
      Returns:
      The title as a String
    • getTitleToolTip

      String getTitleToolTip()
      Returns the tooltip for the container. For an editor that would e.g. be the string that is displayed when hovering over the editor title tab.
      Returns:
      The tooltip as a String
    • refreshTitle

      void refreshTitle()
      Refreshes the title text of this container. It depends on the container type what and if anything is refreshed, for an editor e.g. the part tab will be refreshed.
    • refreshTitleToolTip

      void refreshTitleToolTip()
      Refreshes the title tool tip text of this part. It depends on the container type what and if anything is refreshed, for an editor e.g. the part tab tooltip will be refreshed.
    • isDirty

      boolean isDirty()
      Checks if the container is dirty.
      Returns:
      true, if container is dirty, false otherwise
    • doSave

      void doSave(org.eclipse.core.runtime.IProgressMonitor monitor)
      Triggers that the diagram model is persisted.
    • updateDirtyState

      void updateDirtyState()
      Updates the UI of the container to correctly reflect the dirty state. What (and if anything) happens depends on the container type. The default implementation in the editor e.g. does this by firing a IEditorPart#PROP_DIRTY property change.
    • close

      void close()
      Notify the container that it should shut down or clear it's state.
    • getDiagramTypeProvider

      IDiagramTypeProvider getDiagramTypeProvider()
      Gets the diagram type provider.
      Returns:
      The diagram type provider
    • getDiagramBehavior

      IDiagramBehavior getDiagramBehavior()
      Returns the associated diagram behavior instance, that describes and implements the standard diagram behavior.
      Returns:
      The associated instance of IDiagramBehavior.