Diagram Type Providers

Identifier:
org.eclipse.graphiti.ui.diagramTypeProviders

Since:
0.7.0

Description:
Customers of Graphiti can use this extension point to register their own diagram type providers.

Configuration Markup:

<!ELEMENT extension (diagramTypeProvider*)>

<!ATTLIST extension

point CDATA #REQUIRED

id    CDATA #IMPLIED

name  CDATA #IMPLIED

>


<!ELEMENT diagramTypeProvider (diagramType , imageProvider)*>

<!ATTLIST diagramTypeProvider

id          CDATA #REQUIRED

name        CDATA #REQUIRED

description CDATA #IMPLIED

class       CDATA #REQUIRED

>


<!ELEMENT diagramType EMPTY>

<!ATTLIST diagramType

id IDREF #REQUIRED

>

Advertises that the containing diagram type provider understands the given diagram type and is suitable for editing/viewing diagrams of that type.



<!ELEMENT imageProvider EMPTY>

<!ATTLIST imageProvider

id IDREF #REQUIRED

>

Advertises that the containing diagram type provider needs the given image provider for rendering purposes.



Examples:


   <extension
         point="org.eclipse.graphiti.ui.diagramTypeProviders">
      <diagramTypeProvider
            class="org.eclipse.graphiti.examples.ecore.TestDiagramTypeProvider"
            description="This is a small Ecore test editor for the automated junit tests"
            id="org.eclipse.graphiti.examples.ecore.TestDiagramTypeProvider"
            name="Ecore example editor">
         <diagramType
               id="org.eclipse.graphiti.examples.ecore.EcoreDiagramType">
         </diagramType>
         <imageProvider
               id="org.eclipse.graphiti.examples.common.SampleImageProvider">
         </imageProvider>
      </diagramTypeProvider>
   </extension>

API Information:
Instead of implementing the interface "org.eclipse.graphiti.dt.IDiagramTypeProvider directly, the customer should extend the base class "org.eclipse.graphiti.dt.AbstractDiagramTypeProvider.