org.eclipse.graphiti.platform
Interface IDiagramEditor

All Known Implementing Classes:
DiagramEditor

public interface IDiagramEditor

The Interface IDiagramEditor.


Method Summary
 java.lang.Object executeFeature(IFeature feature, IContext context)
          Executes the given feature in the given context using the command stack and editing domain of the diagram editor.
 IDiagramTypeProvider getDiagramTypeProvider()
          Gets the diagram type provider.
 TransactionalEditingDomain getEditingDomain()
          Gets the transactional editing domain.
 ResourceSet getResourceSet()
          Gets the resource set.
 PictogramElement[] getSelectedPictogramElements()
          Get all pictogram elements currently selected.
 boolean isDirty()
          Checks if is dirty.
 void refresh()
          Refresh.
 void refreshPalette()
          Refreshes the editor's palette.
 void refreshRenderingDecorators(PictogramElement pe)
          Refreshes all rendering decorators for the given pictogram element.
 void refreshTitle()
          Refreshes the title text of this part.
 void refreshTitleToolTip()
          Refreshes the title tool tip text of this part.
 void selectPictogramElements(PictogramElement[] pictogramElements)
          Select all the given pictogram elements in the editor.
 void setPictogramElementForSelection(PictogramElement pictogramElement)
          Sets the pictogram element which should be selected after the editor refresh.
 void setPictogramElementsForSelection(PictogramElement[] pictogramElements)
          Sets the pictogram elements which should be selected after the editor refresh.
 

Method Detail

selectPictogramElements

void selectPictogramElements(PictogramElement[] pictogramElements)
Select all the given pictogram elements in the editor.

Parameters:
pictogramElements - the pictogram elements

getSelectedPictogramElements

PictogramElement[] getSelectedPictogramElements()
Get all pictogram elements currently selected.

Returns:
all selected pictogram elements

setPictogramElementForSelection

void setPictogramElementForSelection(PictogramElement pictogramElement)
Sets the pictogram element which should be selected after the editor refresh.

Parameters:
pictogramElement - the pictogram element

setPictogramElementsForSelection

void setPictogramElementsForSelection(PictogramElement[] pictogramElements)
Sets the pictogram elements which should be selected after the editor refresh.

Parameters:
pictogramElements - the pictogram element

getEditingDomain

TransactionalEditingDomain getEditingDomain()
Gets the transactional editing domain.

Returns:
transactional editing domain which is linked to the editor

getResourceSet

ResourceSet getResourceSet()
Gets the resource set.

Returns:
resource set

getDiagramTypeProvider

IDiagramTypeProvider getDiagramTypeProvider()
Gets the diagram type provider.

Returns:
the diagram type provider

refresh

void refresh()
Refresh.


isDirty

boolean isDirty()
Checks if is dirty.

Returns:
true, if editor is dirty

refreshTitle

void refreshTitle()
Refreshes the title text of this part.

Since:
0.9

refreshTitleToolTip

void refreshTitleToolTip()
Refreshes the title tool tip text of this part.


refreshRenderingDecorators

void refreshRenderingDecorators(PictogramElement pe)
Refreshes all rendering decorators for the given pictogram element. That means: 1. delete current decorators 2. ask the toolbehaviour provider for decorator data 3. create new decorators with this data and render this new decorators

Parameters:
pe - pictogram element

refreshPalette

void refreshPalette()
Refreshes the editor's palette.


executeFeature

java.lang.Object executeFeature(IFeature feature,
                                IContext context)
Executes the given feature in the given context using the command stack and editing domain of the diagram editor. In case of an IAddFeature being passed this method will also trigger the selection of the newly added shape.

Parameters:
feature - The feature to execute
context - The context object to use with the feature
Returns:
an object representing the result of the feature call (depends on the concrete implementation)
Since:
0.9


Copyright (c) SAP AG 2005, 2012.