diff options
author | Benoit Maggi | 2015-03-06 15:12:10 +0000 |
---|---|---|
committer | Benoit Maggi | 2015-03-06 15:12:10 +0000 |
commit | 29c6bab332467e4860195daf1cbd9560b9059220 (patch) | |
tree | 1e8d5a8b63a50cd891146437078f69ffd4de8552 /extraplugins | |
parent | 926f98e686079a91f8dffeb9bbbc6d4b4f39fe75 (diff) | |
download | org.eclipse.papyrus-29c6bab332467e4860195daf1cbd9560b9059220.tar.gz org.eclipse.papyrus-29c6bab332467e4860195daf1cbd9560b9059220.tar.xz org.eclipse.papyrus-29c6bab332467e4860195daf1cbd9560b9059220.zip |
Bug 461597 - [Releng] [domainmodel] Archive the unmaintained project
- remove extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain
Change-Id: I8ddd21e69590dce0b71259a334cc541ae5d5d6cb
Signed-off-by: Benoit Maggi <benoit.maggi@cea.fr>
Diffstat (limited to 'extraplugins')
59 files changed, 0 insertions, 6055 deletions
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.classpath b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.classpath deleted file mode 100644 index ed2585fb3f4..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.classpath +++ /dev/null @@ -1,8 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="src" path="src-gen"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.project b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.project deleted file mode 100644 index a25e6148498..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.project +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.papyrus.uml.diagram.domain</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.settings/org.eclipse.jdt.core.prefs b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 44217f8c068..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,7 +0,0 @@ -eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/META-INF/MANIFEST.MF b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/META-INF/MANIFEST.MF deleted file mode 100644 index 3e983b05d07..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/META-INF/MANIFEST.MF +++ /dev/null @@ -1,35 +0,0 @@ -Manifest-Version: 1.0
-Require-Bundle: org.eclipse.ui,
- org.eclipse.papyrus.uml.diagram.common;bundle-version="1.1.0",
- org.eclipse.papyrus.infra.gmfdiag.common;bundle-version="1.1.0",
- org.eclipse.gmf.runtime.diagram.ui.providers,
- org.eclipse.gmf.runtime.diagram.ui.resources.editor,
- org.eclipse.papyrus.uml.diagram.clazz;bundle-version="1.1.0",
- org.eclipse.papyrus.infra.gmfdiag.preferences;bundle-version="1.1.0",
- org.eclipse.gmf.runtime.notation;bundle-version="1.5.0",
- org.eclipse.gmf.runtime.diagram.core;bundle-version="1.4.1",
- org.eclipse.gmf.runtime.diagram.ui;bundle-version="1.5.0",
- org.eclipse.papyrus.infra.core;bundle-version="1.1.0",
- org.eclipse.uml2.uml;bundle-version="4.0.0",
- org.eclipse.papyrus.infra.core.log;bundle-version="1.1.0",
- org.eclipse.papyrus.infra.core.sasheditor;bundle-version="1.1.0",
- org.eclipse.papyrus.infra.gmfdiag.navigation;bundle-version="1.1.0",
- org.eclipse.ui.ide;bundle-version="3.8.0",
- org.eclipse.emf.common.ui;bundle-version="2.7.0",
- org.eclipse.papyrus.infra.gmfdiag.commands;bundle-version="1.1.0",
- org.eclipse.papyrus.uml.tools;bundle-version="1.1.0",
- org.eclipse.papyrus.infra.widgets;bundle-version="1.1.0",
- org.eclipse.gmf.tooling.runtime;bundle-version="3.1.0",
- org.eclipse.papyrus.uml.diagram.wizards;bundle-version="1.1.0",
- org.eclipse.papyrus.infra.viewpoints.policy;bundle-version="1.1.0"
-Bundle-Vendor: %providerName
-Bundle-ActivationPolicy: lazy
-Bundle-Version: 1.1.0.qualifier
-Bundle-Name: %pluginName
-Bundle-Localization: plugin
-Bundle-ManifestVersion: 2
-Bundle-Activator: org.eclipse.papyrus.uml.diagram.domain.Activator
-Bundle-SymbolicName: org.eclipse.papyrus.uml.diagram.domain;singleton:
- =true
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
-
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/META-INF/MANIFEST.gen.MF b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/META-INF/MANIFEST.gen.MF deleted file mode 100644 index dc2e62893fe..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/META-INF/MANIFEST.gen.MF +++ /dev/null @@ -1,18 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-Localization: plugin -Bundle-SymbolicName: org.eclipse.papyrus.uml.diagram.domain;singleton:=true -Bundle-Version: 0.9.0.qualifier -Bundle-Activator: org.eclipse.papyrus.uml.diagram.domain.Activator -Bundle-Vendor: %providerName -Require-Bundle: org.eclipse.ui, - org.eclipse.core.runtime, - org.eclipse.papyrus.uml.diagram.common, - org.eclipse.papyrus.infra.gmfdiag.common, - org.eclipse.gmf.runtime.diagram.ui.providers, - org.eclipse.gmf.runtime.diagram.ui.resources.editor, - org.eclipse.papyrus.uml.diagram.clazz, - org.eclipse.papyrus.preferences -Bundle-RequiredExecutionEnvironment: J2SE-1.5 -Bundle-ActivationPolicy: lazy diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/about.html b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/about.html deleted file mode 100644 index d35d5aed64c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/about.html +++ /dev/null @@ -1,28 +0,0 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml"> -<head> -<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> -<title>About</title> -</head> -<body lang="EN-US"> -<h2>About This Content</h2> - -<p>June 5, 2007</p> -<h3>License</h3> - -<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise -indicated below, the Content is provided to you under the terms and conditions of the -Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available -at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. -For purposes of the EPL, "Program" will mean the Content.</p> - -<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is -being redistributed by another party ("Redistributor") and different terms and conditions may -apply to your use of any object code in the Content. Check the Redistributor's license that was -provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise -indicated below, the terms and conditions of the EPL still apply to any source code in the Content -and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p> - -</body> -</html> diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/build.gen.properties b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/build.gen.properties deleted file mode 100644 index ca6d14e16f2..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/build.gen.properties +++ /dev/null @@ -1,10 +0,0 @@ -source.. = src/,\ - src-gen/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ - palettes/,\ - icons/,\ - about.html,\ - plugin.properties diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/build.properties b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/build.properties deleted file mode 100644 index 2bc6e042504..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/build.properties +++ /dev/null @@ -1,11 +0,0 @@ -source.. = src/,\
- src-gen/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- plugin.properties,\
- icons/,\
- about.html,\
- palettes/
-src.includes = about.html diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/icons/CategoryDomain.gif b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/icons/CategoryDomain.gif Binary files differdeleted file mode 100644 index 07064ab4727..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/icons/CategoryDomain.gif +++ /dev/null diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/icons/obj16/Domain.gif b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/icons/obj16/Domain.gif Binary files differdeleted file mode 100644 index 40532bafa94..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/icons/obj16/Domain.gif +++ /dev/null diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/palettes/domain.palette.gen.xml b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/palettes/domain.palette.gen.xml deleted file mode 100644 index 1a50078fe02..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/palettes/domain.palette.gen.xml +++ /dev/null @@ -1,85 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" standalone="no"?> -<paletteDefinition> - <content> - <drawer - iconpath="platform:/plugin/org.eclipse.gmf.runtime.diagram.ui/icons/group.gif" - id="org.eclipse.papyrus.uml.diagram.domain.UML_Domain__Tools" name="Tools"> - <aspectTool description="Create a new Class" id="domain.tool.class" - name="Class" refToolId="clazz.tool.class"> - </aspectTool> - <aspectTool description="Create a new Comment" id="domain.tool.comment" - name="Comment" refToolId="clazz.tool.comment"> - </aspectTool> - <aspectTool description="Create a new Constraint" id="domain.tool.constraint" - name="Constraint" refToolId="clazz.tool.constraint"> - </aspectTool> - <aspectTool description="Create a new DataType" id="domain.tool.datatype" - name="DataType" refToolId="clazz.tool.datatype"> - </aspectTool> - <aspectTool description="Create a new Enumeration" id="domain.tool.enumeration" - name="Enumeration" refToolId="clazz.tool.enumeration"> - </aspectTool> - <aspectTool description="Create a new Enumeration" id="domain.tool.enumeration" - name="Enumeration" refToolId="clazz.tool.enumeration"> - </aspectTool> - <aspectTool description="Create a new InstanceSpecification" id="domain.tool.instancespecification" - name="InstanceSpecification" refToolId="clazz.tool.instancespecification"> - </aspectTool> - <aspectTool description="Create a new Package" id="domain.tool.package" - name="Package" refToolId="clazz.tool.package"> - </aspectTool> - <aspectTool description="Create a new PrimitiveType" id="domain.tool.primitivetype" - name="PrimitiveType" refToolId="clazz.tool.primitivetype"> - </aspectTool> - <aspectTool description="Create a new Class" id="domain.tool.class" - name="Class" refToolId="clazz.tool.class"> - </aspectTool> - <aspectTool description="Create a new DataType" id="domain.tool.datatype" - name="DataType" refToolId="clazz.tool.datatype"> - </aspectTool> - <aspectTool description="Create a new Enumeration" id="domain.tool.enumeration" - name="Enumeration" refToolId="clazz.tool.enumeration"> - </aspectTool> - <aspectTool description="Create a new Enumeration literal" id="domain.tool.enumeration literal" - name="Enumeration literal" refToolId="clazz.tool.enumerationliteral"> - </aspectTool> - <aspectTool description="Create a new Interface" id="domain.tool.interface" - name="Interface" refToolId="clazz.tool.interface"> - </aspectTool> - <aspectTool description="Create a new Operation" id="domain.tool.operation" - name="Operation" refToolId="clazz.tool.operation"> - </aspectTool> - <aspectTool description="Create a new PrimitiveType" id="domain.tool.primitivetype" - name="PrimitiveType" refToolId="clazz.tool.primitivetype"> - </aspectTool> - <aspectTool description="Create a new Property" id="domain.tool.property" - name="Property" refToolId="clazz.tool.property"> - </aspectTool> - <aspectTool description="Create a new Reception" id="domain.tool.reception" - name="Reception" refToolId="clazz.tool.reception"> - </aspectTool> - <aspectTool description="Create a new Signal" id="domain.tool.signal" - name="Signal" refToolId="clazz.tool.signal"> - </aspectTool> - <aspectTool description="Create a new Slot" id="domain.tool.slot" - name="Slot" refToolId="clazz.tool.slot"> - </aspectTool> - <aspectTool description="Create a new Association" id="domain.tool.association" - name="Association" refToolId="clazz.tool.association"> - </aspectTool> - <aspectTool description="Create a new CommentLink" id="domain.tool.commentlink" - name="CommentLink" refToolId="clazz.tool.link"> - </aspectTool> - <aspectTool description="Create a new ConstraintConstrainedElement" id="domain.tool.constraintconstrainedelement" - name="ConstraintConstrainedElement" refToolId="clazz.tool.link"> - </aspectTool> - <aspectTool description="Create a new Generalization" id="domain.tool.generalization" - name="Generalization" refToolId="clazz.tool.generalization"> - </aspectTool> - <aspectTool description="Create a new InstanceSpecification" id="domain.tool.instancespecification" - name="InstanceSpecification" refToolId="clazz.tool.instancespecificationlink"> - </aspectTool> - - </drawer> - </content> -</paletteDefinition> diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/palettes/domain.palette.xml b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/palettes/domain.palette.xml deleted file mode 100644 index 7c2827e195b..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/palettes/domain.palette.xml +++ /dev/null @@ -1,34 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" standalone="no"?> - <paletteDefinition> - <content> - <drawer name="Nodes" id="Drawer__1372422134950" iconpath="/icons/drawer.gif"> - <aspectTool name="Class" id="clazz.tool.class_1372422621653" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Class.gif" refToolId="clazz.tool.class" description="Create a new Class"/> - <aspectTool name="Comment" id="clazz.tool.comment_1372422633277" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Comment.gif" refToolId="clazz.tool.comment" description="Create a new Comment"/> - <aspectTool name="DataType" id="clazz.tool.datatype_1372422637235" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/DataType.gif" refToolId="clazz.tool.datatype" description="Create a new DataType"/> - <aspectTool name="Enumeration" id="clazz.tool.enumeration_1372422640538" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Enumeration.gif" refToolId="clazz.tool.enumeration" description="Create a new Enumeration"/> - <aspectTool name="Enumeration literal" id="clazz.tool.enumerationliteral_1372422643873" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/EnumerationLiteral.gif" refToolId="clazz.tool.enumerationliteral" description="Create a new Enumeration literal"/> - <aspectTool name="InstanceSpecification" id="domain.tool.instancespecification" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/InstanceSpecification.gif" refToolId="clazz.tool.instancespecification" description="Create a new InstanceSpecification" /> - <aspectTool name="Operation" id="clazz.tool.operation_1372422687159" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Operation.gif" refToolId="clazz.tool.operation" description="Create a new Operation"/> - <aspectTool name="Package" id="clazz.tool.package_1372422689465" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Package.gif" refToolId="clazz.tool.package" description="Create a new Package"/> - <aspectTool name="PrimitiveType" id="clazz.tool.primitivetype_1372422694264" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/PrimitiveType.gif" refToolId="clazz.tool.primitivetype" description="Create a new PrimitiveType"/> - <aspectTool name="Property" id="clazz.tool.property_1372422697006" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Property.gif" refToolId="clazz.tool.property" description="Create a new Property"/> - <aspectTool name="Slot" id="clazz.tool.slot_1372422710770" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Slot.gif" refToolId="clazz.tool.slot" description="Create a new Slot"/> - </drawer> - <drawer name="Edges" id="drawer_1372422516577" iconpath="/icons/drawer.gif"> - <aspectTool name="Association" id="clazz.tool.association_1372422589274" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Association.gif" refToolId="clazz.tool.association" description="Create a new Association"/> - <aspectTool name="Composition" id="clazz.tool.association_1372422154826" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Association_composite.gif" refToolId="clazz.tool.association" description="Create a new Composition"> - <postAction id="org.eclipse.papyrus.postaction.associationendactionprovider"> - <associationEnd name="source" index="0"> - <multiplicity value="1..1"/> - </associationEnd> - <associationEnd name="target" index="1"> - <aggregation value="composite"/> - <multiplicity value="0..*"/> - </associationEnd> - </postAction> - </aspectTool> - <aspectTool name="Generalization" id="clazz.tool.generalization_1372422593840" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Generalization.gif" refToolId="clazz.tool.generalization" description="Create a new Generalization"/> - <aspectTool name="InstanceSpecification" id="clazz.tool.instancespecificationlink_1372422599325" iconpath="platform:/plugin/org.eclipse.uml2.uml.edit/icons/full/obj16/Association.gif" refToolId="clazz.tool.instancespecificationlink" description="Create a new InstanceSpecification"/> - </drawer> - </content> -</paletteDefinition> diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.gen.xml b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.gen.xml deleted file mode 100644 index b6a5394284f..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.gen.xml +++ /dev/null @@ -1,757 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<?eclipse version="3.4"?> -<plugin> - -<!-- Diagram declaration --> -<extension point="org.eclipse.papyrus.infra.core.papyrusDiagram"> - <creationCommand - creationCommandClass="org.eclipse.papyrus.uml.diagram.domain.DomainDiagramCreateCommand" - icon="icons/obj16/Domain.gif" - id="org.eclipse.papyrus.uml.diagram.domain.CreateCommand" - language="uml" - label="UML Domain Diagram"/> - <editorDiagram - actionBarContributorId="org.eclipse.papyrus.uml.diagram.common.part.UMLDiagramActionBarContributor" - factoryClass="org.eclipse.papyrus.uml.diagram.domain.DomainDiagramEditorFactory" - icon="icons/obj16/Domain.gif" /> -</extension> - -<!-- Diagram creation command and handler --> -<extension point="org.eclipse.ui.commands"> - <command id="org.eclipse.papyrus.uml.diagram.domain.CreateCommand" - name="Create a new Domain Diagram" - description="Create a new Domain Diagram" - categoryId="org.eclipse.papyrus.editor.category"/> -</extension> - -<extension point="org.eclipse.ui.handlers"> - <handler - class="org.eclipse.papyrus.uml.diagram.domain.DomainDiagramCreateCommand" - commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand"> - <activeWhen> - <with variable="activeEditorId"> - <equals value="org.eclipse.papyrus.infra.core.papyrusEditor" /> - </with> - </activeWhen> - </handler> -</extension> - -<!-- Diagram creation command registration in menu and toolbar --> -<extension point="org.eclipse.ui.menus"> - - <menuContribution locationURI="menu:org.eclipse.papyrus.ui.menu"> - <menu id="org.eclipse.papyrus.uml.diagram.ui.menu.diagrams" label="Diagrams"> - <command commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand" - icon="icons/obj16/Domain.gif" label="Create a new Domain Diagram" - style="push" tooltip="Create a new Domain Diagram"> - <visibleWhen> - <reference definitionId="org.eclipse.papyrus.uml.diagram.common.IsPapyrusActiveWithUMLModel"/> - </visibleWhen> - - </command> - </menu> - </menuContribution> - - <menuContribution locationURI="toolbar:org.eclipse.ui.main.toolbar"> - <toolbar id="org.eclipse.papyrus.uml.diagram.ui.toolbar"> - <command commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand" - icon="icons/obj16/Domain.gif" label="Create a new Domain Diagram" - style="push" tooltip="Create a new Domain Diagram"> - <visibleWhen> - <reference definitionId="org.eclipse.papyrus.uml.diagram.common.IsPapyrusActiveWithUMLModel"/> - </visibleWhen> - - </command> - </toolbar> - </menuContribution> - - <menuContribution locationURI="popup:org.eclipse.papyrus.views.modelexplorer.popupmenu.creatediagram"> - <command commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand" - icon="icons/obj16/Domain.gif" - label="Create a new Domain Diagram" - style="push" - tooltip="Create a new Domain Diagram"> - <visibleWhen> - <reference definitionId="org.eclipse.papyrus.uml.diagram.common.IsPapyrusActiveWithUMLModel"/> - </visibleWhen> - - </command> - </menuContribution> - -</extension> - -<!-- Palette tool declaration (declares the real palette containment) --> -<extension point="org.eclipse.papyrus.uml.diagram.common.paletteDefinition" - name="UML_Domain"> - - <paletteDefinition ID="UML_Domain" - class="org.eclipse.papyrus.uml.diagram.common.service.PluginPaletteProvider" - name="UML_Domain" icon="platform:/plugin/org.eclipse.gmf.runtime.diagram.ui/icons/group.gif" - path="palettes/domain.palette.xml" - provider="CEA LIST"> - <Priority name="Low"/> - - <!-- Specify diagram this palette tools relate to --> - <editor id="org.eclipse.papyrus.uml.diagram.domain"/> - </paletteDefinition> -</extension> - -<!-- Diagram view providers declaration --> -<extension point="org.eclipse.gmf.runtime.diagram.core.viewProviders"> - <!-- Diagram view provider --> - <viewProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.DomainDiagramViewProvider"> - <Priority name="Low"/> - <context viewClass="org.eclipse.gmf.runtime.notation.Diagram" semanticHints="domain"/> - </viewProvider> - - <!-- ViewProvider for inherited elements (from ClassDiagram ViewProvider) --> - <viewProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.InheritedClassDiagramViewProvider"> - <Priority name="Low"/> - - <!-- - "2007" = PACKAGE - "3009" = PACKAGE_CN - "2012" = COMMENT - "3028" = COMMENT_CN - "2011" = CONSTRAINT - "3029" = CONSTRAINT_CN - "2001" = INSTANCE_SPECIFICATION - "3020" = INSTANCE_SPECIFICATION_CN - "2008" = CLASS - "3010" = CLASS_CN - "2010" = DATA_TYPE - "3027" = DATA_TYPE_CN - "2006" = ENUMERATION - "3025" = ENUMERATION_CN - "3026" = PRIMITIVE_TYPE_CN - "2009" = PRIMITIVE_TYPE - --> - <context viewClass="org.eclipse.gmf.runtime.notation.Node" semanticHints="2007, 3009, 2012, 3028, 2011, 3029, 2001, 3020, 2008, 3010, 2010, 3027, 2006, 3025, 3026, 2009"/> - - <!-- - "3030" = INSTANCE_SPECIFICATION_SLOT_CLN - "3012" = CLASS_PROPERTY_CLN - "3011" = CLASS_RECEPTION_CLN - "3013" = CLASS_OPERATION_CLN - "3014" = CLASS_CLASS_CLN - "3036" = CLASS_INTERFACE_CLN - "3052" = CLASS_ENUMERATION_CLN - "3047" = CLASS_PRIMITIVE_TYPE_CLN - "3044" = CLASS_DATA_TYPE_CLN - "3050" = CLASS_SIGNAL_CLN - "3018" = DATA_TYPE_PROPERTY_CLN - "3019" = DATA_TYPE_OPERATION_CLN - "3017" = ENUMERATION_ENUMERATION_LITERAL_CLN - "3041" = PRIMITIVE_TYPE_PROPERTY_CLN - "3042" = PRIMITIVE_TYPE_OPERATION_CLN - --> - <context viewClass="org.eclipse.gmf.runtime.notation.Node" semanticHints="3030, 3012, 3011, 3013, 3014, 3036, 3052, 3047, 3044, 3050, 3018, 3019, 3017, 3041, 3042"/> - - <!-- - "4013" = COMMENT_ANNOTATED_ELEMENT - "4014" = CONSTRAINT_CONSTRAINED_ELEMENT - "4002" = GENERALIZATION - "4021" = INSTANCE_SPECIFICATION - "4001" = ASSOCIATION - --> - <context viewClass="org.eclipse.gmf.runtime.notation.Edge" semanticHints="4013, 4014, 4002, 4021, 4001"/> - - <object id="elementtype.node" - class="org.eclipse.papyrus.gmf.diagram.common.commands.ISemanticHintAdapter(org.eclipse.papyrus.sysml.diagram.common)"> - - <method - name="getSemanticHint()" - value="2007, 3009, 2012, 3028, 2011, 3029, 2001, 3020, 2008, 3010, 2010, 3027, 2006, 3025, 3026, 2009"> - </method> - </object> - <context viewClass="org.eclipse.gmf.runtime.notation.Node" elements="elementtype.node"/> - - <object id="elementtype.edge" - class="org.eclipse.papyrus.gmf.diagram.common.commands.ISemanticHintAdapter(org.eclipse.papyrus.sysml.diagram.common)"> - - <method - name="getSemanticHint()" - value="4013, 4014, 4002, 4021, 4001"> - </method> - </object> - <context viewClass="org.eclipse.gmf.runtime.notation.Edge" elements="elementtype.edge"/> - - - <!-- Additional descriptors provided in case the semantic hint is is not provided --> - - <!-- "uml.Package" --> - <object id="uml.Package" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Package"/> - </object> - - <!-- "uml.Comment" --> - <object id="uml.Comment" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Comment"/> - </object> - - <!-- "uml.Constraint" --> - <object id="uml.Constraint" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Constraint"/> - </object> - - <!-- "uml.InstanceSpecification" --> - <object id="uml.InstanceSpecification" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.InstanceSpecification"/> - </object> - - <!-- "uml.Class" --> - <object id="uml.Class" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Class"/> - </object> - - <!-- "uml.DataType" --> - <object id="uml.DataType" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.DataType"/> - </object> - - <!-- "uml.Enumeration" --> - <object id="uml.Enumeration" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Enumeration"/> - </object> - - <!-- "uml.PrimitiveType" --> - <object id="uml.PrimitiveType" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.PrimitiveType"/> - </object> - - <!-- "uml.Slot" --> - <object id="uml.Slot" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Slot"/> - </object> - - <!-- "uml.Property" --> - <object id="uml.Property" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Property"/> - </object> - - <!-- "uml.Reception" --> - <object id="uml.Reception" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Reception"/> - </object> - - <!-- "uml.Operation" --> - <object id="uml.Operation" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Operation"/> - </object> - - <!-- "uml.Interface" --> - <object id="uml.Interface" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Interface"/> - </object> - - <!-- "uml.Signal" --> - <object id="uml.Signal" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Signal"/> - </object> - - <!-- "uml.EnumerationLiteral" --> - <object id="uml.EnumerationLiteral" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.EnumerationLiteral"/> - </object> - - <!-- "uml.Generalization" --> - <object id="uml.Generalization" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Generalization"/> - </object> - - <!-- "uml.Association" --> - <object id="uml.Association" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)"> - <method name="getProxyClassID()" value="uml.Association"/> - </object> - - <!-- Additional activation contexts for nodes semantic objects --> - <context viewClass="org.eclipse.gmf.runtime.notation.Node" - elements="uml.Package, uml.Comment, uml.Constraint, uml.InstanceSpecification, uml.Class, uml.DataType, uml.Enumeration, uml.PrimitiveType, uml.Slot, uml.Property, uml.Reception, uml.Operation, uml.Interface, uml.Signal, uml.EnumerationLiteral"/> - - <!-- Additional activation contexts for edges semantic objects --> - <context viewClass="org.eclipse.gmf.runtime.notation.Edge" - elements="uml.Generalization, uml.InstanceSpecification, uml.Association"/> - - </viewProvider> -</extension> - -<!-- Diagram edit part providers declaration --> -<extension point="org.eclipse.gmf.runtime.diagram.ui.editpartProviders"> - - <!-- Diagram edit part provider --> - <editpartProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.DomainDiagramEditPartProvider"> - <Priority name="Low"/> - <object - id="org.eclipse.papyrus.uml.diagram.domain.Diagram" - class="org.eclipse.gmf.runtime.notation.Diagram"> - <method name="getType()" value="domain"/> - </object> - <context views="org.eclipse.papyrus.uml.diagram.domain.Diagram"/> - </editpartProvider> - - <!-- EditPartProvider for inherited elements (from ClassDiagram) --> - <editpartProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.InheritedClassDiagramEditPartProvider"> - <Priority name="Low"/> - <!-- - The semantic hints given here are used in case the provider is not already loaded. - As soon as the provider is loaded its provides method is used. - "2007" = PACKAGE - "5026" = PACKAGE_LABEL_NAME_HINT - "7016" = PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT - "3009" = PACKAGE_CN - "5017" = PACKAGE_CN_LABEL_NAME_HINT - "7010" = PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT - "2012" = COMMENT - "5038" = COMMENT_LABEL_BODY_HINT - "3028" = COMMENT_CN - "5063" = COMMENT_CN_LABEL_BODY_HINT - "2011" = CONSTRAINT - "5037" = CONSTRAINT_LABEL_NAME_HINT - "5159" = CONSTRAINT_LABEL_BODY_HINT - "3029" = CONSTRAINT_CN - "5064" = CONSTRAINT_CN_LABEL_NAME_HINT - "5160" = CONSTRAINT_CN_LABEL_BODY_HINT - "2001" = INSTANCE_SPECIFICATION - "5002" = INSTANCE_SPECIFICATION_LABEL_NAME_HINT - "7001" = INSTANCE_SPECIFICATION_COMPARTMENT_SLOT_HINT - "3020" = INSTANCE_SPECIFICATION_CN - "5040" = INSTANCE_SPECIFICATION_CN_LABEL_NAME_HINT - "7035" = INSTANCE_SPECIFICATION_CN_COMPARTMENT_SLOT_HINT - "2008" = CLASS - "5029" = CLASS_LABEL_NAME_HINT - "7017" = CLASS_COMPARTMENT_ATTRIBUTE_HINT - "7018" = CLASS_COMPARTMENT_OPERATION_HINT - "7019" = CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT - "3010" = CLASS_CN - "5014" = CLASS_CN_LABEL_NAME_HINT - "7011" = CLASS_CN_COMPARTMENT_ATTRIBUTE_HINT - "7012" = CLASS_CN_COMPARTMENT_OPERATION_HINT - "7013" = CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT - "2010" = DATA_TYPE - "5035" = DATA_TYPE_LABEL_NAME_HINT - "7020" = DATA_TYPE_COMPARTMENT_ATTRIBUTE_HINT - "7021" = DATA_TYPE_COMPARTMENT_OPERATION_HINT - "3027" = DATA_TYPE_CN - "5061" = DATA_TYPE_CN_LABEL_NAME_HINT - "7032" = DATA_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT - "7033" = DATA_TYPE_CN_COMPARTMENT_OPERATION_HINT - "2006" = ENUMERATION - "5023" = ENUMERATION_LABEL_NAME_HINT - "7015" = ENUMERATION_COMPARTMENT_ENUMERATION_LITERAL_HINT - "3025" = ENUMERATION_CN - "5055" = ENUMERATION_CN_LABEL_NAME_HINT - "7031" = ENUMERATION_CN_COMPARTMENT_ENUMERATION_LITERAL_HINT - "3026" = PRIMITIVE_TYPE_CN - "5058" = PRIMITIVE_TYPE_CN_LABEL_NAME_HINT - "7041" = PRIMITIVE_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT - "7042" = PRIMITIVE_TYPE_CN_COMPARTMENT_OPERATION_HINT - "2009" = PRIMITIVE_TYPE - "5032" = PRIMITIVE_TYPE_LABEL_NAME_HINT - "7039" = PRIMITIVE_TYPE_COMPARTMENT_ATTRIBUTE_HINT - "7040" = PRIMITIVE_TYPE_COMPARTMENT_OPERATION_HINT - --> - <object - id="PACKAGE" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2007, 5026, 7016"/> - </object> - <object - id="PACKAGE_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3009, 5017, 7010"/> - </object> - <object - id="COMMENT" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2012, 5038"/> - </object> - <object - id="COMMENT_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3028, 5063"/> - </object> - <object - id="CONSTRAINT" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2011, 5037, 5159"/> - </object> - <object - id="CONSTRAINT_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3029, 5064, 5160"/> - </object> - <object - id="INSTANCE_SPECIFICATION" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2001, 5002, 7001"/> - </object> - <object - id="INSTANCE_SPECIFICATION_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3020, 5040, 7035"/> - </object> - <object - id="CLASS" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2008, 5029, 7017, 7018, 7019"/> - </object> - <object - id="CLASS_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3010, 5014, 7011, 7012, 7013"/> - </object> - <object - id="DATA_TYPE" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2010, 5035, 7020, 7021"/> - </object> - <object - id="DATA_TYPE_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3027, 5061, 7032, 7033"/> - </object> - <object - id="ENUMERATION" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2006, 5023, 7015"/> - </object> - <object - id="ENUMERATION_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3025, 5055, 7031"/> - </object> - <object - id="PRIMITIVE_TYPE_CN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3026, 5058, 7041, 7042"/> - </object> - <object - id="PRIMITIVE_TYPE" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="2009, 5032, 7039, 7040"/> - </object> - - <!-- - "3030" = INSTANCE_SPECIFICATION_SLOT_CLN - "3012" = CLASS_PROPERTY_CLN - "3011" = CLASS_RECEPTION_CLN - "3013" = CLASS_OPERATION_CLN - "3014" = CLASS_CLASS_CLN - "3036" = CLASS_INTERFACE_CLN - "3052" = CLASS_ENUMERATION_CLN - "3047" = CLASS_PRIMITIVE_TYPE_CLN - "3044" = CLASS_DATA_TYPE_CLN - "3050" = CLASS_SIGNAL_CLN - "3018" = DATA_TYPE_PROPERTY_CLN - "3019" = DATA_TYPE_OPERATION_CLN - "3017" = ENUMERATION_ENUMERATION_LITERAL_CLN - "3041" = PRIMITIVE_TYPE_PROPERTY_CLN - "3042" = PRIMITIVE_TYPE_OPERATION_CLN - --> - <object - id="INSTANCE_SPECIFICATION_SLOT_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3030"/> - </object> - <object - id="CLASS_PROPERTY_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3012"/> - </object> - <object - id="CLASS_RECEPTION_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3011"/> - </object> - <object - id="CLASS_OPERATION_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3013"/> - </object> - <object - id="CLASS_CLASS_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3014"/> - </object> - <object - id="CLASS_INTERFACE_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3036"/> - </object> - <object - id="CLASS_ENUMERATION_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3052"/> - </object> - <object - id="CLASS_PRIMITIVE_TYPE_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3047"/> - </object> - <object - id="CLASS_DATA_TYPE_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3044"/> - </object> - <object - id="CLASS_SIGNAL_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3050"/> - </object> - <object - id="DATA_TYPE_PROPERTY_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3018"/> - </object> - <object - id="DATA_TYPE_OPERATION_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3019"/> - </object> - <object - id="ENUMERATION_ENUMERATION_LITERAL_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3017"/> - </object> - <object - id="PRIMITIVE_TYPE_PROPERTY_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3041"/> - </object> - <object - id="PRIMITIVE_TYPE_OPERATION_CLN" - class="org.eclipse.gmf.runtime.notation.Node"> - <method name="getType()" value="3042"/> - </object> - - <!-- - "4013" = COMMENT_ANNOTATED_ELEMENT - "4014" = CONSTRAINT_CONSTRAINED_ELEMENT - "4002" = GENERALIZATION - "6007" = GENERALIZATION_LABEL_APPLIED_STEREOTYPER_HINT - "4021" = INSTANCE_SPECIFICATION - "6039" = INSTANCE_SPECIFICATION_LABEL_SOURCE_IS_LINK_LABEL_HINT - "6038" = INSTANCE_SPECIFICATION_LABEL_TARGET_IS_LINK_LABEL_HINT - "4001" = ASSOCIATION - "6001" = ASSOCIATION_LABEL_APPLIED_STEREOTYPE_HINT - "6002" = ASSOCIATION_LABEL_NAME_HINT - "6003" = ASSOCIATION_LABEL_TARGET_NAME_HINT - "6005" = ASSOCIATION_LABEL_SOURCE_NAME_HINT - "6033" = ASSOCIATION_LABEL_MULTIPLICITY_SOURCE_HINT - "6034" = ASSOCIATION_LABEL_MULTIPLICITY_TARGET_HINT - --> - <object - id="COMMENT_ANNOTATED_ELEMENT" - class="org.eclipse.gmf.runtime.notation.Edge"> - <method name="getType()" value="4013"/> - </object> - <object - id="CONSTRAINT_CONSTRAINED_ELEMENT" - class="org.eclipse.gmf.runtime.notation.Edge"> - <method name="getType()" value="4014"/> - </object> - <object - id="GENERALIZATION" - class="org.eclipse.gmf.runtime.notation.Edge"> - <method name="getType()" value="4002, 6007"/> - </object> - <object - id="INSTANCE_SPECIFICATION" - class="org.eclipse.gmf.runtime.notation.Edge"> - <method name="getType()" value="4021, 6039, 6038"/> - </object> - <object - id="ASSOCIATION" - class="org.eclipse.gmf.runtime.notation.Edge"> - <method name="getType()" value="4001, 6001, 6002, 6003, 6005, 6033, 6034"/> - </object> - - <context views="PACKAGE, PACKAGE_CN, COMMENT, COMMENT_CN, CONSTRAINT, CONSTRAINT_CN, INSTANCE_SPECIFICATION, INSTANCE_SPECIFICATION_CN, CLASS, CLASS_CN, DATA_TYPE, DATA_TYPE_CN, ENUMERATION, ENUMERATION_CN, PRIMITIVE_TYPE_CN, PRIMITIVE_TYPE"/> - <context views="INSTANCE_SPECIFICATION_SLOT_CLN, CLASS_PROPERTY_CLN, CLASS_RECEPTION_CLN, CLASS_OPERATION_CLN, CLASS_CLASS_CLN, CLASS_INTERFACE_CLN, CLASS_ENUMERATION_CLN, CLASS_PRIMITIVE_TYPE_CLN, CLASS_DATA_TYPE_CLN, CLASS_SIGNAL_CLN, DATA_TYPE_PROPERTY_CLN, DATA_TYPE_OPERATION_CLN, ENUMERATION_ENUMERATION_LITERAL_CLN, PRIMITIVE_TYPE_PROPERTY_CLN, PRIMITIVE_TYPE_OPERATION_CLN"/> - <context views="COMMENT_ANNOTATED_ELEMENT, CONSTRAINT_CONSTRAINED_ELEMENT, GENERALIZATION, INSTANCE_SPECIFICATION, ASSOCIATION"/> - - </editpartProvider> -</extension> - -<!-- Diagram edit policy provider --> -<extension - point="org.eclipse.gmf.runtime.diagram.ui.editpolicyProviders"> - <editpolicyProvider - class="org.eclipse.papyrus.uml.diagram.domain.provider.DomainDiagramEditPolicyProvider"> - <Priority name="Low"/> - </editpolicyProvider> -</extension> - -<!-- Preference pages declaration --> -<extension point="org.eclipse.ui.preferencePages" id="prefpages"> - - <!-- Diagram Preference pages declaration --> - <page - id="org.eclipse.papyrus.uml.diagram.domain.preferences" - name="Domain Diagram" - category="org.eclipse.papyrus.preferences.diagrams" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.DomainDiagramGeneralPreferencePage"> - </page> - - <!-- Element Preference pages declaration --> - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.PackagePreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.PackagePreferencePage" - name="Package"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentPreferencePage" - name="Comment"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintPreferencePage" - name="Constraint"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.InstanceSpecificationPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.InstanceSpecificationPreferencePage" - name="InstanceSpecification"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.ClassPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.ClassPreferencePage" - name="Class"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.DataTypePreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.DataTypePreferencePage" - name="DataType"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage" - name="Enumeration"> - </page> - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage" - name="Enumeration"> - </page> - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.PrimitiveTypePreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.PrimitiveTypePreferencePage" - name="PrimitiveType"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentLinkPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentLinkPreferencePage" - name="CommentLink"> - </page> - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintConstrainedElementPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintConstrainedElementPreferencePage" - name="ConstraintConstrainedElement"> - </page> - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.GeneralizationPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.GeneralizationPreferencePage" - name="Generalization"> - </page> - - - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.AssociationPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.AssociationPreferencePage" - name="Association"> - </page> - - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.SlotPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.SlotPreferencePage" - name="Slot"> - </page> - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.PropertyPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.PropertyPreferencePage" - name="Property"> - </page> - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.ReceptionPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.ReceptionPreferencePage" - name="Reception"> - </page> - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.OperationPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.OperationPreferencePage" - name="Operation"> - </page> - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.InterfacePreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.InterfacePreferencePage" - name="Interface"> - </page> - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.SignalPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.SignalPreferencePage" - name="Signal"> - </page> - - <page category="org.eclipse.papyrus.uml.diagram.domain.preferences" - class="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationLiteralPreferencePage" - id="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationLiteralPreferencePage" - name="EnumerationLiteral"> - </page> - - -</extension> - -<!-- // Start of user code custom extensions - --> - -<!-- Insert custom extensions here. --> - -<!-- // End of user code - --> - -</plugin>
\ No newline at end of file diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.properties b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.properties deleted file mode 100644 index ee3cd0d001d..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.properties +++ /dev/null @@ -1,12 +0,0 @@ -################################################################################# -# Copyright (c) 2010 CEA LIST. -# All rights reserved. This program and the accompanying materials -# are made available under the terms of the Eclipse Public License v1.0 -# which accompanies this distribution, and is available at -# http://www.eclipse.org/legal/epl-v10.html -# -# Contributors: -# Yann Tanguy (CEA LIST) yann.tanguy@cea.fr - initial API and implementation -################################################################################## -pluginName=UML Domain Diagram -providerName=Eclipse Modeling Project diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.xml b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.xml deleted file mode 100644 index 913686cfcc3..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/plugin.xml +++ /dev/null @@ -1,782 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
- <extension point="org.eclipse.ui.contexts" id="ui-context">
- <?gmfgen generated="true"?>
- <context
- description="%context.description"
- id="org.eclipse.papyrus.uml.diagram.domain.part.DomainDiagramEditorID"
- name="%context.name"
- parentId="org.eclipse.gmf.runtime.diagram.ui.diagramContext">
- </context>
- </extension>
-
-<!-- Diagram declaration -->
-<extension point="org.eclipse.papyrus.infra.core.papyrusDiagram">
- <creationCommand
- creationCommandClass="org.eclipse.papyrus.uml.diagram.domain.DomainDiagramCreateCommand"
- icon="icons/obj16/Domain.gif"
- id="org.eclipse.papyrus.uml.diagram.domain.CreateCommand"
- language="domain"
- label="UML Domain Diagram"/>
- <editorDiagram
- actionBarContributorId="org.eclipse.papyrus.uml.diagram.common.part.UMLDiagramActionBarContributor"
- factoryClass="org.eclipse.papyrus.uml.diagram.domain.DomainDiagramEditorFactory"
- icon="icons/obj16/Domain.gif" />
- <diagramCategory
- class="org.eclipse.papyrus.uml.diagram.domain.command.CreateDomainModelCommand"
- description="Domain model"
- icon="icons/CategoryDomain.gif"
- id="domain"
- label="Domain">
- </diagramCategory>
-</extension>
-
-<!-- Diagram creation command and handler -->
-<extension point="org.eclipse.ui.commands">
- <command id="org.eclipse.papyrus.uml.diagram.domain.CreateCommand"
- name="Create a new Domain Diagram"
- description="Create a new Domain Diagram"
- categoryId="org.eclipse.papyrus.editor.category"/>
-</extension>
-
-<extension point="org.eclipse.ui.handlers">
- <handler
- class="org.eclipse.papyrus.uml.diagram.domain.DomainDiagramCreateCommand"
- commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand">
- <activeWhen>
- <with variable="activeEditorId">
- <equals value="org.eclipse.papyrus.infra.core.papyrusEditor" />
- </with>
- </activeWhen>
- </handler>
-</extension>
-
-<!-- Diagram creation command registration in menu and toolbar -->
-<extension point="org.eclipse.ui.menus">
-
- <menuContribution locationURI="menu:org.eclipse.papyrus.ui.menu">
- <menu id="org.eclipse.papyrus.uml.diagram.ui.menu.diagrams" label="Diagrams">
- <command commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand"
- icon="icons/obj16/Domain.gif" label="Create a new Domain Diagram"
- style="push" tooltip="Create a new Domain Diagram">
- <visibleWhen>
- <reference definitionId="org.eclipse.papyrus.uml.diagram.common.IsPapyrusActiveWithUMLModel"/>
- </visibleWhen>
-
- </command>
- </menu>
- </menuContribution>
-
- <menuContribution locationURI="toolbar:org.eclipse.ui.main.toolbar">
- <toolbar id="org.eclipse.papyrus.uml.diagram.ui.toolbar">
- <command commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand"
- icon="icons/obj16/Domain.gif" label="Create a new Domain Diagram"
- style="push" tooltip="Create a new Domain Diagram">
- <visibleWhen>
- <reference definitionId="org.eclipse.papyrus.uml.diagram.common.IsPapyrusActiveWithUMLModel"/>
- </visibleWhen>
-
- </command>
- </toolbar>
- </menuContribution>
-
- <menuContribution locationURI="popup:org.eclipse.papyrus.views.modelexplorer.popupmenu.creatediagram">
- <command commandId="org.eclipse.papyrus.uml.diagram.domain.CreateCommand"
- icon="icons/obj16/Domain.gif"
- label="Create a new Domain Diagram"
- style="push"
- tooltip="Create a new Domain Diagram">
- <visibleWhen>
- <reference definitionId="org.eclipse.papyrus.uml.diagram.common.IsPapyrusActiveWithUMLModel"/>
- </visibleWhen>
-
- </command>
- </menuContribution>
-
-</extension>
-
-<!-- Palette tool declaration (declares the real palette containment) -->
-<extension point="org.eclipse.papyrus.uml.diagram.common.paletteDefinition"
- name="UML_Domain">
-
- <paletteDefinition ID="UML_Domain"
- class="org.eclipse.papyrus.uml.diagram.common.service.PluginPaletteProvider"
- name="UML_Domain" icon="platform:/plugin/org.eclipse.gmf.runtime.diagram.ui/icons/group.gif"
- path="palettes/domain.palette.xml"
- provider="CEA LIST">
- <Priority name="Low"/>
-
- <!-- Specify diagram this palette tools relate to -->
- <editor id="org.eclipse.papyrus.uml.diagram.domain"/>
- </paletteDefinition>
-</extension>
-
-<!-- Diagram view providers declaration -->
-<extension point="org.eclipse.gmf.runtime.diagram.core.viewProviders">
- <!-- Diagram view provider -->
- <viewProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.DomainDiagramViewProvider">
- <Priority name="Low"/>
- <context viewClass="org.eclipse.gmf.runtime.notation.Diagram" semanticHints="domain"/>
- </viewProvider>
-
- <!-- ViewProvider for inherited elements (from ClassDiagram ViewProvider) -->
- <viewProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.InheritedClassDiagramViewProvider">
- <Priority name="Low"/>
-
- <!--
- "2007" = PACKAGE
- "3009" = PACKAGE_CN
- "2012" = COMMENT
- "3028" = COMMENT_CN
- "2011" = CONSTRAINT
- "3029" = CONSTRAINT_CN
- "2001" = INSTANCE_SPECIFICATION
- "3020" = INSTANCE_SPECIFICATION_CN
- "2008" = CLASS
- "3010" = CLASS_CN
- "2010" = DATA_TYPE
- "3027" = DATA_TYPE_CN
- "2006" = ENUMERATION
- "3025" = ENUMERATION_CN
- "3026" = PRIMITIVE_TYPE_CN
- "2009" = PRIMITIVE_TYPE
- -->
- <context viewClass="org.eclipse.gmf.runtime.notation.Node" semanticHints="2007, 3009, 2012, 3028, 2011, 3029, 2001, 3020, 2008, 3010, 2010, 3027, 2006, 3025, 3026, 2009"/>
-
- <!--
- "3030" = INSTANCE_SPECIFICATION_SLOT_CLN
- "3012" = CLASS_PROPERTY_CLN
- "3011" = CLASS_RECEPTION_CLN
- "3013" = CLASS_OPERATION_CLN
- "3014" = CLASS_CLASS_CLN
- "3036" = CLASS_INTERFACE_CLN
- "3052" = CLASS_ENUMERATION_CLN
- "3047" = CLASS_PRIMITIVE_TYPE_CLN
- "3044" = CLASS_DATA_TYPE_CLN
- "3050" = CLASS_SIGNAL_CLN
- "3018" = DATA_TYPE_PROPERTY_CLN
- "3019" = DATA_TYPE_OPERATION_CLN
- "3017" = ENUMERATION_ENUMERATION_LITERAL_CLN
- "3041" = PRIMITIVE_TYPE_PROPERTY_CLN
- "3042" = PRIMITIVE_TYPE_OPERATION_CLN
- -->
- <context viewClass="org.eclipse.gmf.runtime.notation.Node" semanticHints="3030, 3012, 3011, 3013, 3014, 3036, 3052, 3047, 3044, 3050, 3018, 3019, 3017, 3041, 3042"/>
-
- <!--
- "4013" = COMMENT_ANNOTATED_ELEMENT
- "4014" = CONSTRAINT_CONSTRAINED_ELEMENT
- "4002" = GENERALIZATION
- "4021" = INSTANCE_SPECIFICATION
- "4001" = ASSOCIATION
- -->
- <context viewClass="org.eclipse.gmf.runtime.notation.Edge" semanticHints="4013, 4014, 4002, 4021, 4001"/>
-
- <object id="elementtype.node"
- class="org.eclipse.papyrus.gmf.diagram.common.commands.ISemanticHintAdapter(org.eclipse.papyrus.sysml.diagram.common)">
-
- <method
- name="getSemanticHint()"
- value="2007, 3009, 2012, 3028, 2011, 3029, 2001, 3020, 2008, 3010, 2010, 3027, 2006, 3025, 3026, 2009">
- </method>
- </object>
- <context viewClass="org.eclipse.gmf.runtime.notation.Node" elements="elementtype.node"/>
-
- <object id="elementtype.edge"
- class="org.eclipse.papyrus.gmf.diagram.common.commands.ISemanticHintAdapter(org.eclipse.papyrus.sysml.diagram.common)">
-
- <method
- name="getSemanticHint()"
- value="4013, 4014, 4002, 4021, 4001">
- </method>
- </object>
- <context viewClass="org.eclipse.gmf.runtime.notation.Edge" elements="elementtype.edge"/>
-
-
- <!-- Additional descriptors provided in case the semantic hint is is not provided -->
-
- <!-- "uml.Package" -->
- <object id="uml.Package" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Package"/>
- </object>
-
- <!-- "uml.Comment" -->
- <object id="uml.Comment" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Comment"/>
- </object>
-
- <!-- "uml.Constraint" -->
- <object id="uml.Constraint" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Constraint"/>
- </object>
-
- <!-- "uml.InstanceSpecification" -->
- <object id="uml.InstanceSpecification" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.InstanceSpecification"/>
- </object>
-
- <!-- "uml.Class" -->
- <object id="uml.Class" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Class"/>
- </object>
-
- <!-- "uml.DataType" -->
- <object id="uml.DataType" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.DataType"/>
- </object>
-
- <!-- "uml.Enumeration" -->
- <object id="uml.Enumeration" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Enumeration"/>
- </object>
-
- <!-- "uml.PrimitiveType" -->
- <object id="uml.PrimitiveType" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.PrimitiveType"/>
- </object>
-
- <!-- "uml.Slot" -->
- <object id="uml.Slot" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Slot"/>
- </object>
-
- <!-- "uml.Property" -->
- <object id="uml.Property" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Property"/>
- </object>
-
- <!-- "uml.Reception" -->
- <object id="uml.Reception" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Reception"/>
- </object>
-
- <!-- "uml.Operation" -->
- <object id="uml.Operation" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Operation"/>
- </object>
-
- <!-- "uml.Interface" -->
- <object id="uml.Interface" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Interface"/>
- </object>
-
- <!-- "uml.Signal" -->
- <object id="uml.Signal" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Signal"/>
- </object>
-
- <!-- "uml.EnumerationLiteral" -->
- <object id="uml.EnumerationLiteral" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.EnumerationLiteral"/>
- </object>
-
- <!-- "uml.Generalization" -->
- <object id="uml.Generalization" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Generalization"/>
- </object>
-
- <!-- "uml.Association" -->
- <object id="uml.Association" class="org.eclipse.gmf.runtime.emf.core.util.IProxyEObject(org.eclipse.gmf.runtime.emf.core)">
- <method name="getProxyClassID()" value="uml.Association"/>
- </object>
-
- <!-- Additional activation contexts for nodes semantic objects -->
- <context viewClass="org.eclipse.gmf.runtime.notation.Node"
- elements="uml.Package, uml.Comment, uml.Constraint, uml.InstanceSpecification, uml.Class, uml.DataType, uml.Enumeration, uml.PrimitiveType, uml.Slot, uml.Property, uml.Reception, uml.Operation, uml.Interface, uml.Signal, uml.EnumerationLiteral"/>
-
- <!-- Additional activation contexts for edges semantic objects -->
- <context viewClass="org.eclipse.gmf.runtime.notation.Edge"
- elements="uml.Generalization, uml.InstanceSpecification, uml.Association"/>
-
- </viewProvider>
-</extension>
-
-<!-- Diagram edit part providers declaration -->
-<extension point="org.eclipse.gmf.runtime.diagram.ui.editpartProviders">
-
- <!-- Diagram edit part provider -->
- <editpartProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.DomainDiagramEditPartProvider">
- <Priority name="Low"/>
- <object
- id="org.eclipse.papyrus.uml.diagram.domain.Diagram"
- class="org.eclipse.gmf.runtime.notation.Diagram">
- <method name="getType()" value="domain"/>
- </object>
- <context views="org.eclipse.papyrus.uml.diagram.domain.Diagram"/>
- </editpartProvider>
-
- <!-- EditPartProvider for inherited elements (from ClassDiagram) -->
- <editpartProvider class="org.eclipse.papyrus.uml.diagram.domain.provider.InheritedClassDiagramEditPartProvider">
- <Priority name="Low"/>
- <!--
- The semantic hints given here are used in case the provider is not already loaded.
- As soon as the provider is loaded its provides method is used.
- "2007" = PACKAGE
- "5026" = PACKAGE_LABEL_NAME_HINT
- "7016" = PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT
- "3009" = PACKAGE_CN
- "5017" = PACKAGE_CN_LABEL_NAME_HINT
- "7010" = PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT
- "2012" = COMMENT
- "5038" = COMMENT_LABEL_BODY_HINT
- "3028" = COMMENT_CN
- "5063" = COMMENT_CN_LABEL_BODY_HINT
- "2011" = CONSTRAINT
- "5037" = CONSTRAINT_LABEL_NAME_HINT
- "5159" = CONSTRAINT_LABEL_BODY_HINT
- "3029" = CONSTRAINT_CN
- "5064" = CONSTRAINT_CN_LABEL_NAME_HINT
- "5160" = CONSTRAINT_CN_LABEL_BODY_HINT
- "2001" = INSTANCE_SPECIFICATION
- "5002" = INSTANCE_SPECIFICATION_LABEL_NAME_HINT
- "7001" = INSTANCE_SPECIFICATION_COMPARTMENT_SLOT_HINT
- "3020" = INSTANCE_SPECIFICATION_CN
- "5040" = INSTANCE_SPECIFICATION_CN_LABEL_NAME_HINT
- "7035" = INSTANCE_SPECIFICATION_CN_COMPARTMENT_SLOT_HINT
- "2008" = CLASS
- "5029" = CLASS_LABEL_NAME_HINT
- "7017" = CLASS_COMPARTMENT_ATTRIBUTE_HINT
- "7018" = CLASS_COMPARTMENT_OPERATION_HINT
- "7019" = CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT
- "3010" = CLASS_CN
- "5014" = CLASS_CN_LABEL_NAME_HINT
- "7011" = CLASS_CN_COMPARTMENT_ATTRIBUTE_HINT
- "7012" = CLASS_CN_COMPARTMENT_OPERATION_HINT
- "7013" = CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT
- "2010" = DATA_TYPE
- "5035" = DATA_TYPE_LABEL_NAME_HINT
- "7020" = DATA_TYPE_COMPARTMENT_ATTRIBUTE_HINT
- "7021" = DATA_TYPE_COMPARTMENT_OPERATION_HINT
- "3027" = DATA_TYPE_CN
- "5061" = DATA_TYPE_CN_LABEL_NAME_HINT
- "7032" = DATA_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT
- "7033" = DATA_TYPE_CN_COMPARTMENT_OPERATION_HINT
- "2006" = ENUMERATION
- "5023" = ENUMERATION_LABEL_NAME_HINT
- "7015" = ENUMERATION_COMPARTMENT_ENUMERATION_LITERAL_HINT
- "3025" = ENUMERATION_CN
- "5055" = ENUMERATION_CN_LABEL_NAME_HINT
- "7031" = ENUMERATION_CN_COMPARTMENT_ENUMERATION_LITERAL_HINT
- "3026" = PRIMITIVE_TYPE_CN
- "5058" = PRIMITIVE_TYPE_CN_LABEL_NAME_HINT
- "7041" = PRIMITIVE_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT
- "7042" = PRIMITIVE_TYPE_CN_COMPARTMENT_OPERATION_HINT
- "2009" = PRIMITIVE_TYPE
- "5032" = PRIMITIVE_TYPE_LABEL_NAME_HINT
- "7039" = PRIMITIVE_TYPE_COMPARTMENT_ATTRIBUTE_HINT
- "7040" = PRIMITIVE_TYPE_COMPARTMENT_OPERATION_HINT
- -->
- <object
- id="PACKAGE"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2007, 5026, 7016"/>
- </object>
- <object
- id="PACKAGE_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3009, 5017, 7010"/>
- </object>
- <object
- id="COMMENT"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2012, 5038"/>
- </object>
- <object
- id="COMMENT_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3028, 5063"/>
- </object>
- <object
- id="CONSTRAINT"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2011, 5037, 5159"/>
- </object>
- <object
- id="CONSTRAINT_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3029, 5064, 5160"/>
- </object>
- <object
- id="INSTANCE_SPECIFICATION"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2001, 5002, 7001"/>
- </object>
- <object
- id="INSTANCE_SPECIFICATION_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3020, 5040, 7035"/>
- </object>
- <object
- id="CLASS"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2008, 5029, 7017, 7018, 7019"/>
- </object>
- <object
- id="CLASS_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3010, 5014, 7011, 7012, 7013"/>
- </object>
- <object
- id="DATA_TYPE"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2010, 5035, 7020, 7021"/>
- </object>
- <object
- id="DATA_TYPE_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3027, 5061, 7032, 7033"/>
- </object>
- <object
- id="ENUMERATION"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2006, 5023, 7015"/>
- </object>
- <object
- id="ENUMERATION_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3025, 5055, 7031"/>
- </object>
- <object
- id="PRIMITIVE_TYPE_CN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3026, 5058, 7041, 7042"/>
- </object>
- <object
- id="PRIMITIVE_TYPE"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="2009, 5032, 7039, 7040"/>
- </object>
-
- <!--
- "3030" = INSTANCE_SPECIFICATION_SLOT_CLN
- "3012" = CLASS_PROPERTY_CLN
- "3011" = CLASS_RECEPTION_CLN
- "3013" = CLASS_OPERATION_CLN
- "3014" = CLASS_CLASS_CLN
- "3036" = CLASS_INTERFACE_CLN
- "3052" = CLASS_ENUMERATION_CLN
- "3047" = CLASS_PRIMITIVE_TYPE_CLN
- "3044" = CLASS_DATA_TYPE_CLN
- "3050" = CLASS_SIGNAL_CLN
- "3018" = DATA_TYPE_PROPERTY_CLN
- "3019" = DATA_TYPE_OPERATION_CLN
- "3017" = ENUMERATION_ENUMERATION_LITERAL_CLN
- "3041" = PRIMITIVE_TYPE_PROPERTY_CLN
- "3042" = PRIMITIVE_TYPE_OPERATION_CLN
- -->
- <object
- id="INSTANCE_SPECIFICATION_SLOT_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3030"/>
- </object>
- <object
- id="CLASS_PROPERTY_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3012"/>
- </object>
- <object
- id="CLASS_RECEPTION_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3011"/>
- </object>
- <object
- id="CLASS_OPERATION_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3013"/>
- </object>
- <object
- id="CLASS_CLASS_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3014"/>
- </object>
- <object
- id="CLASS_INTERFACE_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3036"/>
- </object>
- <object
- id="CLASS_ENUMERATION_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3052"/>
- </object>
- <object
- id="CLASS_PRIMITIVE_TYPE_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3047"/>
- </object>
- <object
- id="CLASS_DATA_TYPE_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3044"/>
- </object>
- <object
- id="CLASS_SIGNAL_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3050"/>
- </object>
- <object
- id="DATA_TYPE_PROPERTY_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3018"/>
- </object>
- <object
- id="DATA_TYPE_OPERATION_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3019"/>
- </object>
- <object
- id="ENUMERATION_ENUMERATION_LITERAL_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3017"/>
- </object>
- <object
- id="PRIMITIVE_TYPE_PROPERTY_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3041"/>
- </object>
- <object
- id="PRIMITIVE_TYPE_OPERATION_CLN"
- class="org.eclipse.gmf.runtime.notation.Node">
- <method name="getType()" value="3042"/>
- </object>
-
- <!--
- "4013" = COMMENT_ANNOTATED_ELEMENT
- "4014" = CONSTRAINT_CONSTRAINED_ELEMENT
- "4002" = GENERALIZATION
- "6007" = GENERALIZATION_LABEL_APPLIED_STEREOTYPER_HINT
- "4021" = INSTANCE_SPECIFICATION
- "6039" = INSTANCE_SPECIFICATION_LABEL_SOURCE_IS_LINK_LABEL_HINT
- "6038" = INSTANCE_SPECIFICATION_LABEL_TARGET_IS_LINK_LABEL_HINT
- "4001" = ASSOCIATION
- "6001" = ASSOCIATION_LABEL_APPLIED_STEREOTYPE_HINT
- "6002" = ASSOCIATION_LABEL_NAME_HINT
- "6003" = ASSOCIATION_LABEL_TARGET_NAME_HINT
- "6005" = ASSOCIATION_LABEL_SOURCE_NAME_HINT
- "6033" = ASSOCIATION_LABEL_MULTIPLICITY_SOURCE_HINT
- "6034" = ASSOCIATION_LABEL_MULTIPLICITY_TARGET_HINT
- -->
- <object
- id="COMMENT_ANNOTATED_ELEMENT"
- class="org.eclipse.gmf.runtime.notation.Edge">
- <method name="getType()" value="4013"/>
- </object>
- <object
- id="CONSTRAINT_CONSTRAINED_ELEMENT"
- class="org.eclipse.gmf.runtime.notation.Edge">
- <method name="getType()" value="4014"/>
- </object>
- <object
- id="GENERALIZATION"
- class="org.eclipse.gmf.runtime.notation.Edge">
- <method name="getType()" value="4002, 6007"/>
- </object>
- <object
- id="INSTANCE_SPECIFICATION"
- class="org.eclipse.gmf.runtime.notation.Edge">
- <method name="getType()" value="4021, 6039, 6038"/>
- </object>
- <object
- id="ASSOCIATION"
- class="org.eclipse.gmf.runtime.notation.Edge">
- <method name="getType()" value="4001, 6001, 6002, 6003, 6005, 6033, 6034"/>
- </object>
-
- <context views="PACKAGE, PACKAGE_CN, COMMENT, COMMENT_CN, CONSTRAINT, CONSTRAINT_CN, INSTANCE_SPECIFICATION, INSTANCE_SPECIFICATION_CN, CLASS, CLASS_CN, DATA_TYPE, DATA_TYPE_CN, ENUMERATION, ENUMERATION_CN, PRIMITIVE_TYPE_CN, PRIMITIVE_TYPE"/>
- <context views="INSTANCE_SPECIFICATION_SLOT_CLN, CLASS_PROPERTY_CLN, CLASS_RECEPTION_CLN, CLASS_OPERATION_CLN, CLASS_CLASS_CLN, CLASS_INTERFACE_CLN, CLASS_ENUMERATION_CLN, CLASS_PRIMITIVE_TYPE_CLN, CLASS_DATA_TYPE_CLN, CLASS_SIGNAL_CLN, DATA_TYPE_PROPERTY_CLN, DATA_TYPE_OPERATION_CLN, ENUMERATION_ENUMERATION_LITERAL_CLN, PRIMITIVE_TYPE_PROPERTY_CLN, PRIMITIVE_TYPE_OPERATION_CLN"/>
- <context views="COMMENT_ANNOTATED_ELEMENT, CONSTRAINT_CONSTRAINED_ELEMENT, GENERALIZATION, INSTANCE_SPECIFICATION, ASSOCIATION"/>
-
- </editpartProvider>
-</extension>
-
-<!-- Diagram edit policy provider -->
-<extension
- point="org.eclipse.gmf.runtime.diagram.ui.editpolicyProviders">
- <editpolicyProvider
- class="org.eclipse.papyrus.uml.diagram.domain.provider.DomainDiagramEditPolicyProvider">
- <Priority name="Low"/>
- </editpolicyProvider>
-</extension>
-
-<!-- Preference pages declaration -->
-<extension point="org.eclipse.ui.preferencePages" id="prefpages">
-
- <!-- Diagram Preference pages declaration -->
- <page
- id="org.eclipse.papyrus.uml.diagram.domain.preferences"
- name="Domain Diagram"
- category="org.eclipse.papyrus.preferences.diagrams"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.DomainDiagramGeneralPreferencePage">
- </page>
-
- <!-- Element Preference pages declaration -->
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.PackagePreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.PackagePreferencePage"
- name="Package">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentPreferencePage"
- name="Comment">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintPreferencePage"
- name="Constraint">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.InstanceSpecificationPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.InstanceSpecificationPreferencePage"
- name="InstanceSpecification">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.ClassPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.ClassPreferencePage"
- name="Class">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.DataTypePreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.DataTypePreferencePage"
- name="DataType">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage"
- name="Enumeration">
- </page>
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage"
- name="Enumeration">
- </page>
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.PrimitiveTypePreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.PrimitiveTypePreferencePage"
- name="PrimitiveType">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentLinkPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.CommentLinkPreferencePage"
- name="CommentLink">
- </page>
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintConstrainedElementPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintConstrainedElementPreferencePage"
- name="ConstraintConstrainedElement">
- </page>
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.GeneralizationPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.GeneralizationPreferencePage"
- name="Generalization">
- </page>
-
-
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.AssociationPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.AssociationPreferencePage"
- name="Association">
- </page>
-
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.SlotPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.SlotPreferencePage"
- name="Slot">
- </page>
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.PropertyPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.PropertyPreferencePage"
- name="Property">
- </page>
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.ReceptionPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.ReceptionPreferencePage"
- name="Reception">
- </page>
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.OperationPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.OperationPreferencePage"
- name="Operation">
- </page>
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.InterfacePreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.InterfacePreferencePage"
- name="Interface">
- </page>
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.SignalPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.SignalPreferencePage"
- name="Signal">
- </page>
-
- <page category="org.eclipse.papyrus.uml.diagram.domain.preferences"
- class="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationLiteralPreferencePage"
- id="org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationLiteralPreferencePage"
- name="EnumerationLiteral">
- </page>
-
-
-</extension>
-
-<!-- // Start of user code custom extensions
- -->
-<extension
- point="org.eclipse.papyrus.uml.diagram.wizards.templates">
- <template
- file="resource/ModelWithBasicTypes.uml"
- id="org.eclipse.papyrus.uml.diagam.domain.model"
- language="domain"
- name="A Domain Model with basic primitive types">
- </template>
-</extension>
-
-<!-- Insert custom extensions here. -->
-
-<!-- // End of user code
- -->
-
-</plugin>
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/pom.xml b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/pom.xml deleted file mode 100644 index 6269d6b391f..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/pom.xml +++ /dev/null @@ -1,12 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<project> - <modelVersion>4.0.0</modelVersion> - <parent> - <artifactId>org.eclipse.papyrus</artifactId> - <groupId>org.eclipse.papyrus</groupId> - <version>1.1.0-SNAPSHOT</version> - <relativePath>../../../releng/top-pom-extras.xml</relativePath> - </parent> - <artifactId>org.eclipse.papyrus.uml.diagram.domain</artifactId> - <packaging>eclipse-plugin</packaging> -</project>
\ No newline at end of file diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/resource/ModelWithBasicTypes.uml b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/resource/ModelWithBasicTypes.uml deleted file mode 100644 index daea222ff6f..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/resource/ModelWithBasicTypes.uml +++ /dev/null @@ -1,6 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?>
-<uml:Model xmi:version="2.1" xmlns:xmi="http://schema.omg.org/spec/XMI/2.1" xmlns:uml="http://www.eclipse.org/uml2/3.0.0/UML" xmi:id="_xRouMOTjEd6E-IWFQ_MzPA" name="Model">
- <packageImport xmi:id="_F2B_UOTkEd6E-IWFQ_MzPA">
- <importedPackage xmi:type="uml:Model" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#_0"/>
- </packageImport>
-</uml:Model>
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/resource/UML.Domain.idgen b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/resource/UML.Domain.idgen deleted file mode 100644 index e7f800e6e3c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/resource/UML.Domain.idgen +++ /dev/null @@ -1,75 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?>
-<idgen:Diagram xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:gmfgen="http://www.eclipse.org/gmf/2009/GenModel" xmlns:idgen="http://www.eclipse.org/papyrus/0.7.0/idgen" name="Domain" type="domain" icon="icons/obj16/Domain.gif" label="UML Domain Diagram" language="uml" javaPackagePrefix="org.eclipse.papyrus.uml.diagram.domain" javaClassPrefix="DomainDiagram" createCommandLabel="Create a new Domain Diagram">
- <diagramEditPart name="PackageDiagramEditPart">
- <behaviors javaClassQualifiedName="org.eclipse.papyrus.uml.diagram.common.editpolicies.DuplicatePasteEditPolicy" key="DuplicatePasteEditPolicy.PASTE_ROLE"/>
- <behaviors javaClassQualifiedName="org.eclipse.papyrus.uml.diagram.clazz.edit.policies.ModelItemSemanticEditPolicy" key="EditPolicyRoles.SEMANTIC_ROLE"/>
- <behaviors name="" javaClassQualifiedName="org.eclipse.papyrus.uml.diagram.clazz.custom.policies.RemoveOrphanViewPolicy" key=""RemoveOrphanView""/>
- <behaviors name="" javaClassQualifiedName="org.eclipse.papyrus.uml.diagram.domain.policies.CustomDragDropEditPolicy" key="EditPolicyRoles.DRAG_DROP_ROLE"/>
- </diagramEditPart>
- <inheritedDiagrams name="ClassDiagram" viewProviderClassQualifiedName="" editPartProviderClassQualifiedName="" dndEditPolicyClassQualifiedName="org.eclipse.papyrus.uml.diagram.clazz.custom.policies.ClassDiagramDragDropEditPolicy">
- <genInheritedEditor href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#PapyrusUMLClassDiagram"/>
- <genNodes customPreferencePage="">
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.9"/>
- </genNodes>
- <genNodes customPreferencePage="" generatePreferencePage="false" generateTool="false">
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.31"/>
- </genNodes>
- <genNodes name="">
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.15"/>
- </genNodes>
- <genNodes generatePreferencePage="false" generateTool="false">
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.36"/>
- </genNodes>
- <genNodes>
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.14"/>
- </genNodes>
- <genNodes generatePreferencePage="false" generateTool="false">
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.37"/>
- </genNodes>
- <genNodes>
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.3"/>
- </genNodes>
- <genNodes generatePreferencePage="false" generateTool="false">
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.25"/>
- </genNodes>
- <genNodes>
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.11"/>
- </genNodes>
- <genNodes generatePreferencePage="false" generateTool="false">
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.33"/>
- </genNodes>
- <genNodes>
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.13"/>
- </genNodes>
- <genNodes generatePreferencePage="false" generateTool="false">
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.35"/>
- </genNodes>
- <genNodes>
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.8"/>
- </genNodes>
- <genNodes>
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.30"/>
- </genNodes>
- <genNodes>
- <genNode xsi:type="gmfgen:GenChildNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@childNodes.34"/>
- </genNodes>
- <genNodes generatePreferencePage="false" generateTool="false">
- <genNode xsi:type="gmfgen:GenTopLevelNode" href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@topLevelNodes.12"/>
- </genNodes>
- <genLinks name="CommentLink" customPreferencePage="">
- <genLink href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@links.16"/>
- </genLinks>
- <genLinks>
- <genLink href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@links.17"/>
- </genLinks>
- <genLinks>
- <genLink href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@links.4"/>
- </genLinks>
- <genLinks name="" generatePreferencePage="false">
- <genLink href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@links.20"/>
- </genLinks>
- <genLinks>
- <genLink href="../../org.eclipse.papyrus.uml.diagram.clazz/model/classdiagram.gmfgen#/0/@diagram/@links.2"/>
- </genLinks>
- </inheritedDiagrams>
-</idgen:Diagram>
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/Activator.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/Activator.java deleted file mode 100644 index c52d413cd7e..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/Activator.java +++ /dev/null @@ -1,108 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain; - -import org.eclipse.gmf.runtime.diagram.core.preferences.PreferencesHint; -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.jface.resource.ImageDescriptor; -import org.eclipse.papyrus.infra.core.log.LogHelper; -import org.eclipse.papyrus.uml.diagram.domain.preferences.DomainDiagramPreferenceInitializer; -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** The activator class controls the plug-in life cycle */ -public class Activator extends AbstractUIPlugin { - - /** The plug-in ID */ - public static final String PLUGIN_ID = "org.eclipse.papyrus.uml.diagram.domain"; - - /** The plug-in shared instance */ - private static Activator plugin; - - /** The logging helper */ - public static LogHelper log; - - /** The plug-in Preference store */ - public static final PreferencesHint DIAGRAM_PREFERENCES_HINT = new PreferencesHint(PLUGIN_ID); - - /** Default constructor */ - public Activator() { - } - - /* - * (non-Javadoc) - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - @Override - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - - // register the login helper - log = new LogHelper(plugin); - - // register the preference store - PreferencesHint.registerPreferenceStore(DIAGRAM_PREFERENCES_HINT, getPreferenceStore()); - - // Preferences initialization - DomainDiagramPreferenceInitializer diagramPreferenceInitializer = new DomainDiagramPreferenceInitializer(); - diagramPreferenceInitializer.initializeDefaultPreferences(); - } - - /* - * (non-Javadoc) - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - @Override - public void stop(BundleContext context) throws Exception { - log = null; - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance - * - * @return the shared instance - */ - public static Activator getInstance() { - return plugin; - } - - /** - * Returns an image descriptor for the image file at the given plug-in relative path. - * - * @generated - * @param path - * the path - * @return the image descriptor - */ - public static ImageDescriptor getBundledImageDescriptor(String path) { - return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, path); - } - - /** - * - * @see org.eclipse.ui.plugin.AbstractUIPlugin#getPreferenceStore() - * - * @return Shared Preference Store. - */ - @Override - public IPreferenceStore getPreferenceStore() { - IPreferenceStore store = org.eclipse.papyrus.infra.gmfdiag.preferences.Activator.getDefault().getPreferenceStore(); - return store; - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramCreateCommand.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramCreateCommand.java deleted file mode 100644 index 7d1dc5f252c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramCreateCommand.java +++ /dev/null @@ -1,52 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain; - -import org.eclipse.gmf.runtime.diagram.core.preferences.PreferencesHint; -import org.eclipse.papyrus.infra.gmfdiag.common.AbstractPapyrusGmfCreateDiagramCommandHandler; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -// Start of user code custom imports -// End of user code - -public class DomainDiagramCreateCommand extends AbstractPapyrusGmfCreateDiagramCommandHandler { - - /** - * {@inheritDoc} - */ - @Override - protected String getDefaultDiagramName() { - return "NewDiagram"; //$NON-NLS-1$ - } - - /** - * {@inheritDoc} - */ - @Override - protected String getDiagramNotationID() { - return ElementTypes.DIAGRAM_ID; - } - - /** - * {@inheritDoc} - */ - @Override - protected PreferencesHint getPreferenceHint() { - return Activator.DIAGRAM_PREFERENCES_HINT; - } - - // Start of user code Custom creation command - - // End of user code -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramEditorFactory.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramEditorFactory.java deleted file mode 100644 index 7ad89d97e6e..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramEditorFactory.java +++ /dev/null @@ -1,25 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain; - -import org.eclipse.papyrus.infra.gmfdiag.common.GmfEditorFactory; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class DomainDiagramEditorFactory extends GmfEditorFactory { - - public DomainDiagramEditorFactory() { - super(DomainDiagramForMultiEditor.class, ElementTypes.DIAGRAM_ID); - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramForMultiEditor.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramForMultiEditor.java deleted file mode 100644 index 76f4783b5d9..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/DomainDiagramForMultiEditor.java +++ /dev/null @@ -1,116 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.ui.URIEditorInput; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.gmf.runtime.notation.Diagram; -import org.eclipse.jface.dialogs.ErrorDialog; -import org.eclipse.jface.resource.ImageDescriptor; -import org.eclipse.papyrus.infra.core.editor.BackboneException; -import org.eclipse.papyrus.infra.core.services.ServiceException; -import org.eclipse.papyrus.infra.core.services.ServicesRegistry; -import org.eclipse.papyrus.uml.diagram.domain.part.DomainDiagramEditor; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorSite; -import org.eclipse.ui.PartInitException; - -/** - * An editor to be used in multitabs editor. This editor extends the original UML Diagram. - * - */ -public class DomainDiagramForMultiEditor extends DomainDiagramEditor { - - /** - * The location of diagram icon in the plug-in - */ - private static final String DIAG_IMG_PATH = "icons/obj16/Domain.gif"; - - /** - * The image descriptor of the diagram icon - */ - private static final ImageDescriptor DIAG_IMG_DESC = Activator.getBundledImageDescriptor(DomainDiagramForMultiEditor.DIAG_IMG_PATH); - - /** The editor splitter. */ - private Composite splitter; - - /** - * Constructor for SashSystem v2. Context and required objects are retrieved from the - * ServiceRegistry. - * - * @throws BackboneException - * @throws ServiceException - * - */ - public DomainDiagramForMultiEditor(ServicesRegistry servicesRegistry, Diagram diagram) throws BackboneException, ServiceException { - super(servicesRegistry, diagram); - } - - /** - * {@inheritDoc} - */ - @Override - public void init(IEditorSite site, IEditorInput input) throws PartInitException { - super.init(site, input); - setPartName(getDiagram().getName()); - setTitleImage(DIAG_IMG_DESC.createImage()); - } - - /** - * {@inheritDoc} - */ - @Override - public void setInput(IEditorInput input) { - try { - // Provide an URI with fragment in order to reuse the same Resource - // and set the diagram to the fragment. - URIEditorInput uriInput = new URIEditorInput(EcoreUtil.getURI(getDiagram())); - doSetInput(uriInput, true); - } catch (CoreException x) { - String title = "Problem opening"; - String msg = "Cannot open input element:"; - Shell shell = getSite().getShell(); - ErrorDialog.openError(shell, title, msg, x.getStatus()); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void createGraphicalViewer(Composite parent) { - splitter = parent; - super.createGraphicalViewer(parent); - } - - /** - * {@inheritDoc} - */ - @Override - public void setFocus() { - splitter.setFocus(); - super.setFocus(); - } - - /** - * {@inheritDoc} - */ - @Override - public String getEditingDomainID() { - return "org.eclipse.papyrus.uml.diagram.domain.EditingDomain"; - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/edit/part/DomainDiagramEditPart.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/edit/part/DomainDiagramEditPart.java deleted file mode 100644 index 762d00c954f..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/edit/part/DomainDiagramEditPart.java +++ /dev/null @@ -1,38 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.edit.part; - -import org.eclipse.gmf.runtime.diagram.ui.editparts.DiagramEditPart; -import org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles; -import org.eclipse.gmf.runtime.notation.View; -import org.eclipse.papyrus.uml.diagram.clazz.custom.policies.RemoveOrphanViewPolicy; -import org.eclipse.papyrus.uml.diagram.clazz.edit.policies.ModelItemSemanticEditPolicy; -import org.eclipse.papyrus.uml.diagram.common.editpolicies.DuplicatePasteEditPolicy; -import org.eclipse.papyrus.uml.diagram.domain.policies.CustomDragDropEditPolicy; - -public class DomainDiagramEditPart extends DiagramEditPart { - - public DomainDiagramEditPart(View view) { - super(view); - } - - @Override - protected void createDefaultEditPolicies() { - super.createDefaultEditPolicies(); - installEditPolicy(DuplicatePasteEditPolicy.PASTE_ROLE, new DuplicatePasteEditPolicy()); - installEditPolicy(EditPolicyRoles.SEMANTIC_ROLE, new ModelItemSemanticEditPolicy()); - installEditPolicy("RemoveOrphanView", new RemoveOrphanViewPolicy()); - installEditPolicy(EditPolicyRoles.DRAG_DROP_ROLE, new CustomDragDropEditPolicy()); - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/edit/policy/DomainDiagramDragDropEditPolicy.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/edit/policy/DomainDiagramDragDropEditPolicy.java deleted file mode 100644 index 78e89c4e02c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/edit/policy/DomainDiagramDragDropEditPolicy.java +++ /dev/null @@ -1,51 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.edit.policy; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.gmf.runtime.notation.View; -import org.eclipse.papyrus.infra.gmfdiag.common.providers.IGraphicalTypeRegistry; -import org.eclipse.papyrus.uml.diagram.clazz.custom.policies.ClassDiagramDragDropEditPolicy; -import org.eclipse.papyrus.uml.diagram.domain.provider.GraphicalTypeRegistry; - -/** Customization of the DND edit policy for the Domain Diagram */ -public class DomainDiagramDragDropEditPolicy extends ClassDiagramDragDropEditPolicy { - - /** Local graphical type registry */ - protected IGraphicalTypeRegistry registry = new GraphicalTypeRegistry(); - - /** - * {@inheritDoc} - */ - @Override - public int getNodeVisualID(View containerView, EObject domainElement) { - String domainType = registry.getNodeGraphicalType(domainElement, containerView.getType()); - if (IGraphicalTypeRegistry.UNDEFINED_TYPE.equals(domainType)) { - return -1; // undefined - } - return new Integer(domainType); - } - - /** - * {@inheritDoc} - */ - @Override - public int getLinkWithClassVisualID(EObject domainElement) { - String domainType = registry.getEdgeGraphicalType(domainElement); - if (IGraphicalTypeRegistry.UNDEFINED_TYPE.equals(domainType)) { - return -1; // undefined - } - return new Integer(domainType); - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/factory/DomainDiagramViewFactory.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/factory/DomainDiagramViewFactory.java deleted file mode 100644 index 5a8540ff502..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/factory/DomainDiagramViewFactory.java +++ /dev/null @@ -1,31 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.factory; - -import org.eclipse.gmf.runtime.diagram.ui.view.factories.DiagramViewFactory; -import org.eclipse.gmf.runtime.notation.MeasurementUnit; - -public class DomainDiagramViewFactory extends DiagramViewFactory { - - // Start of user code Custom view Factory field - // End of user code - - /** - * {@inheritDoc} - */ - @Override - protected MeasurementUnit getMeasurementUnit() { - return MeasurementUnit.PIXEL_LITERAL; - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/part/DomainDiagramEditor.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/part/DomainDiagramEditor.java deleted file mode 100644 index 47ff99bc9e0..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/part/DomainDiagramEditor.java +++ /dev/null @@ -1,513 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.part; - -import java.util.EventObject; -import java.util.Set; - -import org.eclipse.core.commands.operations.IUndoableOperation; -import org.eclipse.core.resources.IMarker; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.emf.transaction.TransactionalEditingDomain; -import org.eclipse.gef.GraphicalViewer; -import org.eclipse.gef.KeyHandler; -import org.eclipse.gef.Tool; -import org.eclipse.gef.commands.CommandStackListener; -import org.eclipse.gef.palette.PaletteRoot; -import org.eclipse.gef.ui.palette.PaletteViewer; -import org.eclipse.gef.ui.palette.PaletteViewerProvider; -import org.eclipse.gmf.runtime.common.core.service.IProviderChangeListener; -import org.eclipse.gmf.runtime.common.core.service.ProviderChangeEvent; -import org.eclipse.gmf.runtime.common.ui.services.marker.MarkerNavigationService; -import org.eclipse.gmf.runtime.diagram.core.preferences.PreferencesHint; -import org.eclipse.gmf.runtime.diagram.ui.actions.ActionIds; -import org.eclipse.gmf.runtime.diagram.ui.internal.parts.PaletteToolTransferDragSourceListener; -import org.eclipse.gmf.runtime.diagram.ui.providers.DiagramContextMenuProvider; -import org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDocumentProvider; -import org.eclipse.gmf.runtime.notation.Diagram; -import org.eclipse.jface.util.LocalSelectionTransfer; -import org.eclipse.jface.viewers.ISelection; -import org.eclipse.papyrus.infra.core.editor.IMultiDiagramEditor; -import org.eclipse.papyrus.infra.core.services.ServiceException; -import org.eclipse.papyrus.infra.core.services.ServicesRegistry; -import org.eclipse.papyrus.infra.gmfdiag.common.GmfMultiDiagramDocumentProvider; -import org.eclipse.papyrus.uml.diagram.common.listeners.DropTargetListener; -import org.eclipse.papyrus.uml.diagram.common.part.PapyrusPaletteContextMenuProvider; -import org.eclipse.papyrus.uml.diagram.common.part.PapyrusPaletteViewer; -import org.eclipse.papyrus.uml.diagram.common.part.UmlGmfDiagramEditor; -import org.eclipse.papyrus.uml.diagram.common.service.PapyrusPaletteService; -import org.eclipse.papyrus.uml.diagram.domain.Activator; -import org.eclipse.swt.SWT; -import org.eclipse.swt.dnd.TransferData; -import org.eclipse.swt.events.KeyEvent; -import org.eclipse.swt.events.MouseEvent; -import org.eclipse.swt.events.MouseListener; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.ui.IEditorInput; -import org.eclipse.ui.IEditorPart; -import org.eclipse.ui.IWorkbenchPart; -import org.eclipse.ui.ide.IGotoMarker; -import org.eclipse.ui.part.ShowInContext; - -/** - * Diagram editor that extends the UMLDiagramEditor editor. - */ -public class DomainDiagramEditor extends UmlGmfDiagramEditor implements IProviderChangeListener, IGotoMarker { - - /** context used when trying to find services */ - public static final String CONTEXT_ID = "org.eclipse.papyrus.uml.diagram.domain.part.DomainDiagramEditorID"; //$NON-NLS-1$ - - /** - * {@inheritDoc} - */ - @Override - public String getContextID() { - return CONTEXT_ID; - } - - /** - * @generated - */ - private KeyHandler paletteKeyHandler = null; - - /** - * @generated - */ - private MouseListener paletteMouseListener = null; - - /** - * @generated - */ - private IUndoableOperation savedOperation = null; - - /** - * @generated - */ - private TransactionalEditingDomain editingDomain; - - /** - * @generated - */ - private IDocumentProvider documentProvider; - - /** - * @generated - */ - public DomainDiagramEditor(ServicesRegistry servicesRegistry, Diagram diagram) throws ServiceException { - super(servicesRegistry, diagram); - - // adds a listener to the palette service, which reacts to palette customizations - PapyrusPaletteService.getInstance().addProviderChangeListener(this); - - // Share the same editing provider - editingDomain = servicesRegistry.getService(TransactionalEditingDomain.class); - documentProvider = new GmfMultiDiagramDocumentProvider(editingDomain); - - // overrides editing domain created by super constructor - setDocumentProvider(documentProvider); - } - - /** - * @generated - */ - @Override - protected PaletteRoot createPaletteRoot(PaletteRoot existingPaletteRoot) { - PaletteRoot paletteRoot; - if (existingPaletteRoot == null) { - paletteRoot = PapyrusPaletteService.getInstance().createPalette(this, getDefaultPaletteContent()); - } else { - PapyrusPaletteService.getInstance().updatePalette(existingPaletteRoot, this, getDefaultPaletteContent()); - paletteRoot = existingPaletteRoot; - } - applyCustomizationsToPalette(paletteRoot); - return paletteRoot; - } - - /** - * @generated - */ - @Override - protected PreferencesHint getPreferencesHint() { - return Activator.DIAGRAM_PREFERENCES_HINT; - } - - /** - * @generated - */ - @Override - public String getContributorId() { - return Activator.PLUGIN_ID; - } - - /** - * @generated - */ - @Override - protected final IDocumentProvider getDocumentProvider(IEditorInput input) { - return documentProvider; - } - - /** - * @generated - */ - @Override - public TransactionalEditingDomain getEditingDomain() { - return editingDomain; - } - - /** - * @generated - */ - @Override - protected final void setDocumentProvider(IEditorInput input) { - // Already set in the constructor - } - - /** - * @generated - */ - public void gotoMarker(IMarker marker) { - MarkerNavigationService.getInstance().gotoMarker(this, marker); - } - - /** - * @generated - */ - @Override - public boolean isSaveAsAllowed() { - return true; - } - - /** - * @generated - */ - @Override - public void doSaveAs() { - performSaveAs(new NullProgressMonitor()); - } - - /** - * @generated - */ - @Override - protected void performSaveAs(IProgressMonitor progressMonitor) { - // Nothing - } - - /** - * @generated - */ - @Override - public ShowInContext getShowInContext() { - return new ShowInContext(getEditorInput(), getGraphicalViewer().getSelection()); - } - - /** - * @generated - */ - @Override - protected void configureGraphicalViewer() { - super.configureGraphicalViewer(); - - // Replace diagram contextual menu removing default - // delete from model action. - DiagramContextMenuProvider provider = (DiagramContextMenuProvider) getDiagramGraphicalViewer().getContextMenu(); - Set<String> menuExclusions = provider.getExclusionSet(); - menuExclusions.add(ActionIds.ACTION_DELETE_FROM_MODEL); - provider.setExclusionSet(menuExclusions); - } - - /** - * @generated - */ - @Override - protected TransactionalEditingDomain createEditingDomain() { - // Already configured - return editingDomain; - } - - /** - * @generated - */ - @Override - protected void configureDiagramEditDomain() { - super.configureDiagramEditDomain(); - getDiagramEditDomain().getDiagramCommandStack().addCommandStackListener(new CommandStackListener() { - - public void commandStackChanged(EventObject event) { - firePropertyChange(IEditorPart.PROP_DIRTY); - } - }); - } - - /** - * @generated - */ - @Override - public void doSave(IProgressMonitor progressMonitor) { - // The saving of the resource is done by the CoreMultiDiagramEditor - savedOperation = getOperationHistory().getUndoOperation(getUndoContext()); - } - - /** - * @generated - */ - @Override - public boolean isDirty() { - IUndoableOperation op = getOperationHistory().getUndoOperation(getUndoContext()); - return savedOperation != op; - } - - /** - * @generated - */ - public void providerChanged(ProviderChangeEvent event) { - // update the palette if the palette service has changed - if (PapyrusPaletteService.getInstance().equals(event.getSource())) { - PapyrusPaletteService.getInstance().updatePalette(getPaletteViewer().getPaletteRoot(), this, getDefaultPaletteContent()); - } - } - - /** - * @generated - */ - @Override - public void dispose() { - // remove palette service listener - // remove preference listener - PapyrusPaletteService.getInstance().removeProviderChangeListener(this); - - super.dispose(); - } - - /** - * @generated - */ - protected PaletteViewer getPaletteViewer() { - return getEditDomain().getPaletteViewer(); - } - - /** - * @generated - */ - @Override - protected PaletteViewer constructPaletteViewer() { - return new PapyrusPaletteViewer(); - } - - /** - * @generated - */ - @Override - protected PaletteViewerProvider createPaletteViewerProvider() { - getEditDomain().setPaletteRoot(createPaletteRoot(null)); - return new PaletteViewerProvider(getEditDomain()) { - - /** - * Override to provide the additional behavior for the tools. Will intialize with a - * PaletteEditPartFactory that has a TrackDragger that understand how to handle the - * mouseDoubleClick event for shape creation tools. Also will initialize the palette - * with a defaultTool that is the SelectToolEx that undestands how to handle the enter - * key which will result in the creation of the shape also. - */ - @Override - protected void configurePaletteViewer(PaletteViewer viewer) { - super.configurePaletteViewer(viewer); - - // customize menu... - viewer.setContextMenu(new PapyrusPaletteContextMenuProvider(viewer)); - - viewer.getKeyHandler().setParent(getPaletteKeyHandler()); - viewer.getControl().addMouseListener(getPaletteMouseListener()); - - // Add a transfer drag target listener that is supported on - // palette template entries whose template is a creation tool. - // This will enable drag and drop of the palette shape creation - // tools. - viewer.addDragSourceListener(new PaletteToolTransferDragSourceListener(viewer)); - viewer.setCustomizer(createPaletteCustomizer()); - } - - @Override - public PaletteViewer createPaletteViewer(Composite parent) { - PaletteViewer pViewer = constructPaletteViewer(); - pViewer.createControl(parent); - configurePaletteViewer(pViewer); - hookPaletteViewer(pViewer); - return pViewer; - } - - /** - * @return Palette Key Handler for the palette - */ - private KeyHandler getPaletteKeyHandler() { - - if (paletteKeyHandler == null) { - - paletteKeyHandler = new KeyHandler() { - - /** - * Processes a <i>key released </i> event. This method is called by the Tool - * whenever a key is released, and the Tool is in the proper state. Override - * to support pressing the enter key to create a shape or connection - * (between two selected shapes) - * - * @param event - * the KeyEvent - * @return <code>true</code> if KeyEvent was handled in some way - */ - @Override - public boolean keyReleased(KeyEvent event) { - - if (event.keyCode == SWT.Selection) { - - Tool tool = getPaletteViewer().getActiveTool().createTool(); - - if (toolSupportsAccessibility(tool)) { - - tool.keyUp(event, getDiagramGraphicalViewer()); - - // deactivate current selection - getPaletteViewer().setActiveTool(null); - - return true; - } - - } - return super.keyReleased(event); - } - - }; - - } - return paletteKeyHandler; - } - - /** - * @return Palette Mouse listener for the palette - */ - private MouseListener getPaletteMouseListener() { - - if (paletteMouseListener == null) { - - paletteMouseListener = new MouseListener() { - - /** - * Flag to indicate that the current active tool should be cleared after a - * mouse double-click event. - */ - private boolean clearActiveTool = false; - - /** - * Override to support double-clicking a palette tool entry to create a - * shape or connection (between two selected shapes). - * - * @see MouseListener#mouseDoubleClick(MouseEvent) - */ - public void mouseDoubleClick(MouseEvent e) { - Tool tool = getPaletteViewer().getActiveTool().createTool(); - - if (toolSupportsAccessibility(tool)) { - - tool.setViewer(getDiagramGraphicalViewer()); - tool.setEditDomain(getDiagramGraphicalViewer().getEditDomain()); - tool.mouseDoubleClick(e, getDiagramGraphicalViewer()); - - // Current active tool should be deactivated, - // but if it is down here it will get - // reactivated deep in GEF palette code after - // receiving mouse up events. - clearActiveTool = true; - } - } - - public void mouseDown(MouseEvent e) { - // do nothing - } - - public void mouseUp(MouseEvent e) { - // Deactivate current active tool here if a - // double-click was handled. - if (clearActiveTool) { - getPaletteViewer().setActiveTool(null); - clearActiveTool = false; - } - - } - }; - - } - return paletteMouseListener; - } - - }; - } - - /** - * @generated - */ - @Override - public GraphicalViewer getGraphicalViewer() { - return super.getGraphicalViewer(); - } - - /** - * @generated - */ - @Override - protected void initializeGraphicalViewer() { - super.initializeGraphicalViewer(); - - // Enable Drop - getDiagramGraphicalViewer().addDropTargetListener(new DropTargetListener(getDiagramGraphicalViewer(), LocalSelectionTransfer.getTransfer()) { - - @Override - protected Object getJavaObject(TransferData data) { - return LocalSelectionTransfer.getTransfer().nativeToJava(data); - } - - @Override - protected TransactionalEditingDomain getTransactionalEditingDomain() { - return getEditingDomain(); - } - }); - - } - - /** - * @generated - */ - @Override - public void selectionChanged(IWorkbenchPart part, ISelection selection) { - if (getSite().getPage().getActiveEditor() instanceof IMultiDiagramEditor) { - IMultiDiagramEditor editor = (IMultiDiagramEditor) getSite().getPage().getActiveEditor(); - // If not the active editor, ignore selection changed. - if (this.equals(editor.getActiveEditor())) { - updateActions(getSelectionActions()); - super.selectionChanged(part, selection); - } else { - super.selectionChanged(part, selection); - } - } else { - super.selectionChanged(part, selection); - } - // from - // org.eclipse.gmf.runtime.diagram.ui.resources.editor.parts.DiagramDocumentEditor.selectionChanged(IWorkbenchPart, - // ISelection) - if (part == this) { - rebuildStatusLine(); - } - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/AssociationPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/AssociationPreferencePage.java deleted file mode 100644 index 1eec51edece..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/AssociationPreferencePage.java +++ /dev/null @@ -1,79 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class AssociationPreferencePage extends DomainDiagramLinkPreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_AssociationLink"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> labelDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - labelDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - labelDefaultVisibilityMap.put("Stereotype", Boolean.TRUE); //$NON-NLS-1$ - labelDefaultVisibilityMap.put("Name", Boolean.TRUE); //$NON-NLS-1$ - labelDefaultVisibilityMap.put("TargetRole", Boolean.TRUE); //$NON-NLS-1$ - labelDefaultVisibilityMap.put("SourceRole", Boolean.TRUE); //$NON-NLS-1$ - labelDefaultVisibilityMap.put("SourceMultiplicity", Boolean.TRUE); //$NON-NLS-1$ - labelDefaultVisibilityMap.put("TargetMultiplicity", Boolean.TRUE); //$NON-NLS-1$ - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(labelDefaultVisibilityMap); - } - - /** Default constructor */ - public AssociationPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_AssociationLink"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - for (String labelName : labelDefaultVisibilityMap.keySet()) { - String showLabelKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, labelName, PreferencesConstantsHelper.LABEL_VISIBILITY); - store.setDefault(showLabelKey, labelDefaultVisibilityMap.get(labelName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeLabelsList() { - for (String name : labelDefaultVisibilityMap.keySet()) { - this.labelsList.add(name); - } - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ClassPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ClassPreferencePage.java deleted file mode 100644 index 3cba15d3960..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ClassPreferencePage.java +++ /dev/null @@ -1,106 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class ClassPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Class"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> compartmentDefaultVisibilityMap; - - /** The compartment titles default visibility for preferences */ - public static final Map<String, Boolean> compartmentTitleDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - compartmentDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentDefaultVisibilityMap.put("AttributeCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentDefaultVisibilityMap.put("OperationCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentDefaultVisibilityMap.put("NestedClassifierCompartment", Boolean.TRUE); //$NON-NLS-1$ - - compartmentTitleDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentTitleDefaultVisibilityMap.put("AttributeCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentTitleDefaultVisibilityMap.put("OperationCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentTitleDefaultVisibilityMap.put("NestedClassifierCompartment", Boolean.TRUE); //$NON-NLS-1$ - - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(compartmentDefaultVisibilityMap); - Collections.unmodifiableMap(compartmentTitleDefaultVisibilityMap); - } - - /** Default constructor */ - public ClassPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Class"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.WIDTH), 100); - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.HEIGHT), 100); - // Initialize default visibility for compartments in preference page. - for (String compartmentName : compartmentDefaultVisibilityMap.keySet()) { - String showCompartmentKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_VISIBILITY); - store.setDefault(showCompartmentKey, compartmentDefaultVisibilityMap.get(compartmentName)); - } - - // Initialize default title visibility for compartments in preference page. - for (String compartmentName : compartmentTitleDefaultVisibilityMap.keySet()) { - String showCompartmentTitleKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_NAME_VISIBILITY); - store.setDefault(showCompartmentTitleKey, compartmentTitleDefaultVisibilityMap.get(compartmentName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentNamesList() { - for (String name : compartmentDefaultVisibilityMap.keySet()) { - this.compartmentNamesList.add(name); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentTitlesList() { - for (String name : compartmentTitleDefaultVisibilityMap.keySet()) { - this.compartmentTitlesList.add(name); - } - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/CommentLinkPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/CommentLinkPreferencePage.java deleted file mode 100644 index a87a0905524..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/CommentLinkPreferencePage.java +++ /dev/null @@ -1,43 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class CommentLinkPreferencePage extends DomainDiagramLinkPreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_CommentAnnotatedElement"; //$NON-NLS-1$ - - - /** Default constructor */ - public CommentLinkPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_CommentAnnotatedElement"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/CommentPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/CommentPreferencePage.java deleted file mode 100644 index 48b9d098d92..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/CommentPreferencePage.java +++ /dev/null @@ -1,44 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class CommentPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Comment"; //$NON-NLS-1$ - - - /** Default constructor */ - public CommentPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Comment"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - } - - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ConstraintConstrainedElementPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ConstraintConstrainedElementPreferencePage.java deleted file mode 100644 index edb9b888716..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ConstraintConstrainedElementPreferencePage.java +++ /dev/null @@ -1,43 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class ConstraintConstrainedElementPreferencePage extends DomainDiagramLinkPreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_ConstraintConstrainedElement"; //$NON-NLS-1$ - - - /** Default constructor */ - public ConstraintConstrainedElementPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_ConstraintConstrainedElement"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ConstraintPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ConstraintPreferencePage.java deleted file mode 100644 index e5b7f9e4dd8..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ConstraintPreferencePage.java +++ /dev/null @@ -1,44 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class ConstraintPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Constraint"; //$NON-NLS-1$ - - - /** Default constructor */ - public ConstraintPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Constraint"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - } - - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DataTypePreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DataTypePreferencePage.java deleted file mode 100644 index fcb20ec309c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DataTypePreferencePage.java +++ /dev/null @@ -1,104 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class DataTypePreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_DataType"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> compartmentDefaultVisibilityMap; - - /** The compartment titles default visibility for preferences */ - public static final Map<String, Boolean> compartmentTitleDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - compartmentDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentDefaultVisibilityMap.put("AttributeCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentDefaultVisibilityMap.put("OperationCompartment", Boolean.TRUE); //$NON-NLS-1$ - - compartmentTitleDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentTitleDefaultVisibilityMap.put("AttributeCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentTitleDefaultVisibilityMap.put("OperationCompartment", Boolean.TRUE); //$NON-NLS-1$ - - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(compartmentDefaultVisibilityMap); - Collections.unmodifiableMap(compartmentTitleDefaultVisibilityMap); - } - - /** Default constructor */ - public DataTypePreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_DataType"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.WIDTH), 100); - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.HEIGHT), 100); - // Initialize default visibility for compartments in preference page. - for (String compartmentName : compartmentDefaultVisibilityMap.keySet()) { - String showCompartmentKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_VISIBILITY); - store.setDefault(showCompartmentKey, compartmentDefaultVisibilityMap.get(compartmentName)); - } - - // Initialize default title visibility for compartments in preference page. - for (String compartmentName : compartmentTitleDefaultVisibilityMap.keySet()) { - String showCompartmentTitleKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_NAME_VISIBILITY); - store.setDefault(showCompartmentTitleKey, compartmentTitleDefaultVisibilityMap.get(compartmentName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentNamesList() { - for (String name : compartmentDefaultVisibilityMap.keySet()) { - this.compartmentNamesList.add(name); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentTitlesList() { - for (String name : compartmentTitleDefaultVisibilityMap.keySet()) { - this.compartmentTitlesList.add(name); - } - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramGeneralPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramGeneralPreferencePage.java deleted file mode 100644 index 19aad6965d5..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramGeneralPreferencePage.java +++ /dev/null @@ -1,24 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.papyrus.infra.gmfdiag.preferences.pages.DiagramPreferencePage; -import org.eclipse.papyrus.uml.diagram.domain.Activator; - -public class DomainDiagramGeneralPreferencePage extends DiagramPreferencePage { - - public DomainDiagramGeneralPreferencePage() { - setPreferenceStore(Activator.getInstance().getPreferenceStore()); - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramLinkPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramLinkPreferencePage.java deleted file mode 100644 index acd5c64f8a0..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramLinkPreferencePage.java +++ /dev/null @@ -1,73 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; -import java.util.TreeMap; - -import org.eclipse.papyrus.infra.gmfdiag.preferences.pages.AbstractPapyrusLinkPreferencePage; -import org.eclipse.papyrus.infra.gmfdiag.preferences.ui.OrderedLabelGroup; -import org.eclipse.papyrus.uml.diagram.domain.Activator; -import org.eclipse.swt.widgets.Composite; - -public class DomainDiagramLinkPreferencePage extends AbstractPapyrusLinkPreferencePage { - - /** The list of label names for this link */ - protected List<String> labelsList; - - /** Constructor */ - public DomainDiagramLinkPreferencePage() { - labelsList = new ArrayList<String>(); - initializeLabelsList(); - Collections.unmodifiableList(labelsList); - } - - /** - * {@inheritDoc} - */ - @Override - protected void createPageContents(Composite parent) { - super.createPageContents(parent); - - // Add label visibility group - if (!labelsList.isEmpty()) { - OrderedLabelGroup compartmentGroup = new OrderedLabelGroup(parent, getPreferenceKey(), this, labelsList); - addAbstractGroup(compartmentGroup); - } - - } - - /** - * {@inheritDoc} - */ - @Override - protected String getBundleId() { - return Activator.PLUGIN_ID; - } - - /** Initialize the list containing names of labels. */ - protected void initializeLabelsList() { - // Implemented by subclasses. - } - - /** - * {@inheritDoc} - */ - @Override - protected final TreeMap<String, String> getLabelRole() { - return new TreeMap<String, String>(); - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramNodePreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramNodePreferencePage.java deleted file mode 100644 index f7ac9830ee9..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramNodePreferencePage.java +++ /dev/null @@ -1,119 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; -import java.util.TreeMap; - -import org.eclipse.papyrus.infra.gmfdiag.preferences.pages.AbstractPapyrusNodePreferencePage; -import org.eclipse.papyrus.infra.gmfdiag.preferences.ui.OrderedCompartmentGroup; -import org.eclipse.papyrus.infra.gmfdiag.preferences.ui.OrderedLabelGroup; -import org.eclipse.papyrus.uml.diagram.domain.Activator; -import org.eclipse.swt.widgets.Composite; - -public class DomainDiagramNodePreferencePage extends AbstractPapyrusNodePreferencePage { - - /** The list owning the names of compartments */ - protected List<String> compartmentNamesList; - - /** The list owning the names of compartment that have a title */ - protected List<String> compartmentTitlesList; - - /** The list of label names for this node */ - protected List<String> labelsList; - - /** Constructor */ - public DomainDiagramNodePreferencePage() { - this.labelsList = new ArrayList<String>(); - this.compartmentNamesList = new ArrayList<String>(); - this.compartmentTitlesList = new ArrayList<String>(); - - initializeLabelsList(); - initializeCompartmentNamesList(); - initializeCompartmentTitlesList(); - - Collections.unmodifiableList(labelsList); - Collections.unmodifiableList(compartmentNamesList); - Collections.unmodifiableList(compartmentTitlesList); - } - - /** - * {@inheritDoc} - */ - @Override - protected void createPageContents(Composite parent) { - super.createPageContents(parent); - - // Add compartments visibility group - if (!compartmentNamesList.isEmpty()) { - OrderedCompartmentGroup compartmentGroup = new OrderedCompartmentGroup(parent, getPreferenceKey(), this, compartmentNamesList, compartmentTitlesList, getPreferenceStore()); - addAbstractGroup(compartmentGroup); - } - - // Add label visibility group - if (!labelsList.isEmpty()) { - OrderedLabelGroup compartmentGroup = new OrderedLabelGroup(parent, getPreferenceKey(), this, labelsList); - addAbstractGroup(compartmentGroup); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected String getBundleId() { - return Activator.PLUGIN_ID; - } - - /** Initialize the list containing names of labels. */ - protected void initializeLabelsList() { - // Implemented by subclasses. - } - - /** Initialize the list containing the names of compartments. */ - protected void initializeCompartmentNamesList() { - // Implemented by subclasses. - } - - /** Initialize the list containing the names of compartment that have titles. */ - protected void initializeCompartmentTitlesList() { - // Implemented by subclasses. - } - - /** - * {@inheritDoc} - */ - @Override - protected final TreeMap<String, String> getLabelRole() { - return new TreeMap<String, String>(); - } - - /** - * {@inheritDoc} - */ - @Override - protected final TreeMap<String, Boolean> getCompartmentTitleVisibilityPreferences() { - return new TreeMap<String, Boolean>(); - } - - /** - * {@inheritDoc} - */ - @Override - protected final void initializeCompartmentsList() { - compartmentsList = Collections.emptyList(); - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramPreferenceInitializer.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramPreferenceInitializer.java deleted file mode 100644 index f6505bd041c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/DomainDiagramPreferenceInitializer.java +++ /dev/null @@ -1,44 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer; -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.Activator; - -public class DomainDiagramPreferenceInitializer extends AbstractPreferenceInitializer { - - protected IPreferenceStore getPreferenceStore() { - return Activator.getInstance().getPreferenceStore(); - } - - @Override - public void initializeDefaultPreferences() { - IPreferenceStore store = getPreferenceStore(); - - org.eclipse.papyrus.uml.diagram.domain.preferences.PackagePreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.CommentPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.InstanceSpecificationPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.ClassPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.DataTypePreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.EnumerationPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.PrimitiveTypePreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.CommentLinkPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.ConstraintConstrainedElementPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.GeneralizationPreferencePage.initDefaults(store); - org.eclipse.papyrus.uml.diagram.domain.preferences.AssociationPreferencePage.initDefaults(store); - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/EnumerationLiteralPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/EnumerationLiteralPreferencePage.java deleted file mode 100644 index da40c1a54ec..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/EnumerationLiteralPreferencePage.java +++ /dev/null @@ -1,40 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class EnumerationLiteralPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_EnumerationLiteral"; //$NON-NLS-1$ - - /** Default constructor */ - public EnumerationLiteralPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_EnumerationLiteral"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/EnumerationPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/EnumerationPreferencePage.java deleted file mode 100644 index 648e4f21d79..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/EnumerationPreferencePage.java +++ /dev/null @@ -1,102 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class EnumerationPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Enumeration"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> compartmentDefaultVisibilityMap; - - /** The compartment titles default visibility for preferences */ - public static final Map<String, Boolean> compartmentTitleDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - compartmentDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentDefaultVisibilityMap.put("EnumerationLiteralCompartment", Boolean.TRUE); //$NON-NLS-1$ - - compartmentTitleDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentTitleDefaultVisibilityMap.put("EnumerationLiteralCompartment", Boolean.TRUE); //$NON-NLS-1$ - - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(compartmentDefaultVisibilityMap); - Collections.unmodifiableMap(compartmentTitleDefaultVisibilityMap); - } - - /** Default constructor */ - public EnumerationPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Enumeration"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.WIDTH), 100); - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.HEIGHT), 100); - // Initialize default visibility for compartments in preference page. - for (String compartmentName : compartmentDefaultVisibilityMap.keySet()) { - String showCompartmentKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_VISIBILITY); - store.setDefault(showCompartmentKey, compartmentDefaultVisibilityMap.get(compartmentName)); - } - - // Initialize default title visibility for compartments in preference page. - for (String compartmentName : compartmentTitleDefaultVisibilityMap.keySet()) { - String showCompartmentTitleKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_NAME_VISIBILITY); - store.setDefault(showCompartmentTitleKey, compartmentTitleDefaultVisibilityMap.get(compartmentName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentNamesList() { - for (String name : compartmentDefaultVisibilityMap.keySet()) { - this.compartmentNamesList.add(name); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentTitlesList() { - for (String name : compartmentTitleDefaultVisibilityMap.keySet()) { - this.compartmentTitlesList.add(name); - } - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/GeneralizationPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/GeneralizationPreferencePage.java deleted file mode 100644 index d704b54a5a2..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/GeneralizationPreferencePage.java +++ /dev/null @@ -1,74 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class GeneralizationPreferencePage extends DomainDiagramLinkPreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Generalization"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> labelDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - labelDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - labelDefaultVisibilityMap.put("Stereotype", Boolean.TRUE); //$NON-NLS-1$ - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(labelDefaultVisibilityMap); - } - - /** Default constructor */ - public GeneralizationPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Generalization"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - for (String labelName : labelDefaultVisibilityMap.keySet()) { - String showLabelKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, labelName, PreferencesConstantsHelper.LABEL_VISIBILITY); - store.setDefault(showLabelKey, labelDefaultVisibilityMap.get(labelName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeLabelsList() { - for (String name : labelDefaultVisibilityMap.keySet()) { - this.labelsList.add(name); - } - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/InstanceSpecificationPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/InstanceSpecificationPreferencePage.java deleted file mode 100644 index 8610ebc069f..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/InstanceSpecificationPreferencePage.java +++ /dev/null @@ -1,102 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class InstanceSpecificationPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_InstanceSpecification"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> compartmentDefaultVisibilityMap; - - /** The compartment titles default visibility for preferences */ - public static final Map<String, Boolean> compartmentTitleDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - compartmentDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentDefaultVisibilityMap.put("SlotCompartment", Boolean.TRUE); //$NON-NLS-1$ - - compartmentTitleDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentTitleDefaultVisibilityMap.put("SlotCompartment", Boolean.TRUE); //$NON-NLS-1$ - - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(compartmentDefaultVisibilityMap); - Collections.unmodifiableMap(compartmentTitleDefaultVisibilityMap); - } - - /** Default constructor */ - public InstanceSpecificationPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_InstanceSpecification"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.WIDTH), 100); - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.HEIGHT), 100); - // Initialize default visibility for compartments in preference page. - for (String compartmentName : compartmentDefaultVisibilityMap.keySet()) { - String showCompartmentKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_VISIBILITY); - store.setDefault(showCompartmentKey, compartmentDefaultVisibilityMap.get(compartmentName)); - } - - // Initialize default title visibility for compartments in preference page. - for (String compartmentName : compartmentTitleDefaultVisibilityMap.keySet()) { - String showCompartmentTitleKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_NAME_VISIBILITY); - store.setDefault(showCompartmentTitleKey, compartmentTitleDefaultVisibilityMap.get(compartmentName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentNamesList() { - for (String name : compartmentDefaultVisibilityMap.keySet()) { - this.compartmentNamesList.add(name); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentTitlesList() { - for (String name : compartmentTitleDefaultVisibilityMap.keySet()) { - this.compartmentTitlesList.add(name); - } - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/InterfacePreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/InterfacePreferencePage.java deleted file mode 100644 index 88fa836fee5..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/InterfacePreferencePage.java +++ /dev/null @@ -1,40 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class InterfacePreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Interface"; //$NON-NLS-1$ - - /** Default constructor */ - public InterfacePreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Interface"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/OperationPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/OperationPreferencePage.java deleted file mode 100644 index d167899c3c5..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/OperationPreferencePage.java +++ /dev/null @@ -1,40 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class OperationPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Operation"; //$NON-NLS-1$ - - /** Default constructor */ - public OperationPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Operation"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PackagePreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PackagePreferencePage.java deleted file mode 100644 index f1e8480187a..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PackagePreferencePage.java +++ /dev/null @@ -1,102 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class PackagePreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Package"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> compartmentDefaultVisibilityMap; - - /** The compartment titles default visibility for preferences */ - public static final Map<String, Boolean> compartmentTitleDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - compartmentDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentDefaultVisibilityMap.put("PackageableElementCompartment", Boolean.TRUE); //$NON-NLS-1$ - - compartmentTitleDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentTitleDefaultVisibilityMap.put("PackageableElementCompartment", Boolean.TRUE); //$NON-NLS-1$ - - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(compartmentDefaultVisibilityMap); - Collections.unmodifiableMap(compartmentTitleDefaultVisibilityMap); - } - - /** Default constructor */ - public PackagePreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Package"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.WIDTH), 200); - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.HEIGHT), 100); - // Initialize default visibility for compartments in preference page. - for (String compartmentName : compartmentDefaultVisibilityMap.keySet()) { - String showCompartmentKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_VISIBILITY); - store.setDefault(showCompartmentKey, compartmentDefaultVisibilityMap.get(compartmentName)); - } - - // Initialize default title visibility for compartments in preference page. - for (String compartmentName : compartmentTitleDefaultVisibilityMap.keySet()) { - String showCompartmentTitleKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_NAME_VISIBILITY); - store.setDefault(showCompartmentTitleKey, compartmentTitleDefaultVisibilityMap.get(compartmentName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentNamesList() { - for (String name : compartmentDefaultVisibilityMap.keySet()) { - this.compartmentNamesList.add(name); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentTitlesList() { - for (String name : compartmentTitleDefaultVisibilityMap.keySet()) { - this.compartmentTitlesList.add(name); - } - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PrimitiveTypePreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PrimitiveTypePreferencePage.java deleted file mode 100644 index 26ef6ff3f27..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PrimitiveTypePreferencePage.java +++ /dev/null @@ -1,104 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class PrimitiveTypePreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_PrimitiveType"; //$NON-NLS-1$ - - /** The compartments default visibility for preferences */ - public static final Map<String, Boolean> compartmentDefaultVisibilityMap; - - /** The compartment titles default visibility for preferences */ - public static final Map<String, Boolean> compartmentTitleDefaultVisibilityMap; - - /** Static attribute initialization */ - static { - compartmentDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentDefaultVisibilityMap.put("AttributeCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentDefaultVisibilityMap.put("OperationCompartment", Boolean.TRUE); //$NON-NLS-1$ - - compartmentTitleDefaultVisibilityMap = new LinkedHashMap<String, Boolean>(); - compartmentTitleDefaultVisibilityMap.put("AttributeCompartment", Boolean.TRUE); //$NON-NLS-1$ - compartmentTitleDefaultVisibilityMap.put("OperationCompartment", Boolean.TRUE); //$NON-NLS-1$ - - - // Start of user code custom static initializations - // End of user code - - Collections.unmodifiableMap(compartmentDefaultVisibilityMap); - Collections.unmodifiableMap(compartmentTitleDefaultVisibilityMap); - } - - /** Default constructor */ - public PrimitiveTypePreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_PrimitiveType"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.WIDTH), 100); - store.setDefault(PreferencesConstantsHelper.getElementConstant(prefKey, PreferencesConstantsHelper.HEIGHT), 50); - // Initialize default visibility for compartments in preference page. - for (String compartmentName : compartmentDefaultVisibilityMap.keySet()) { - String showCompartmentKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_VISIBILITY); - store.setDefault(showCompartmentKey, compartmentDefaultVisibilityMap.get(compartmentName)); - } - - // Initialize default title visibility for compartments in preference page. - for (String compartmentName : compartmentTitleDefaultVisibilityMap.keySet()) { - String showCompartmentTitleKey = PreferencesConstantsHelper.getCompartmentElementConstant(prefKey, compartmentName, PreferencesConstantsHelper.COMPARTMENT_NAME_VISIBILITY); - store.setDefault(showCompartmentTitleKey, compartmentTitleDefaultVisibilityMap.get(compartmentName)); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentNamesList() { - for (String name : compartmentDefaultVisibilityMap.keySet()) { - this.compartmentNamesList.add(name); - } - } - - /** - * {@inheritDoc} - */ - @Override - protected void initializeCompartmentTitlesList() { - for (String name : compartmentTitleDefaultVisibilityMap.keySet()) { - this.compartmentTitlesList.add(name); - } - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PropertyPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PropertyPreferencePage.java deleted file mode 100644 index 5161a340d9c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/PropertyPreferencePage.java +++ /dev/null @@ -1,40 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class PropertyPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Property"; //$NON-NLS-1$ - - /** Default constructor */ - public PropertyPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Property"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ReceptionPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ReceptionPreferencePage.java deleted file mode 100644 index 37731939ed6..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/ReceptionPreferencePage.java +++ /dev/null @@ -1,40 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class ReceptionPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Reception"; //$NON-NLS-1$ - - /** Default constructor */ - public ReceptionPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Reception"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/SignalPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/SignalPreferencePage.java deleted file mode 100644 index 6b4aa9689ae..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/SignalPreferencePage.java +++ /dev/null @@ -1,40 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class SignalPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Signal"; //$NON-NLS-1$ - - /** Default constructor */ - public SignalPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Signal"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/SlotPreferencePage.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/SlotPreferencePage.java deleted file mode 100644 index ef1904bee22..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/preferences/SlotPreferencePage.java +++ /dev/null @@ -1,40 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.preferences; - -import org.eclipse.jface.preference.IPreferenceStore; -import org.eclipse.papyrus.uml.diagram.domain.provider.ElementTypes; - -public class SlotPreferencePage extends DomainDiagramNodePreferencePage { - - /** Constant key to access preferences */ - protected static String prefKey = ElementTypes.DIAGRAM_ID + "_Slot"; //$NON-NLS-1$ - - /** Default constructor */ - public SlotPreferencePage() { - super(); - setPreferenceKey(ElementTypes.DIAGRAM_ID + "_Slot"); //$NON-NLS-1$ - } - - /** - * Initialize defaults using a specified {@link IPreferenceStore} - * - * @param store - * the preference store. - */ - public static void initDefaults(IPreferenceStore store) { - // Start of user code custom default initializations - // End of user code - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramEditPartProvider.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramEditPartProvider.java deleted file mode 100644 index 52908c3fa33..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramEditPartProvider.java +++ /dev/null @@ -1,50 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - -import org.eclipse.gmf.runtime.common.core.service.IOperation; -import org.eclipse.gmf.runtime.diagram.ui.services.editpart.AbstractEditPartProvider; -import org.eclipse.gmf.runtime.diagram.ui.services.editpart.CreateGraphicEditPartOperation; -import org.eclipse.gmf.runtime.diagram.ui.services.editpart.IEditPartOperation; -import org.eclipse.gmf.runtime.notation.View; -import org.eclipse.papyrus.uml.diagram.domain.Activator; -import org.eclipse.papyrus.uml.diagram.domain.edit.part.DomainDiagramEditPart; - -public class DomainDiagramEditPartProvider extends AbstractEditPartProvider { - - @Override - public boolean provides(IOperation operation) { - if (operation instanceof CreateGraphicEditPartOperation) { - View view = ((IEditPartOperation) operation).getView(); - - // Ensure current diagram is Domain Diagram - if (ElementTypes.DIAGRAM_ID.equals(view.getType())) { - return true; - } - } - - return false; - } - - @Override - protected Class<?> getDiagramEditPartClass(View view) { - if (ElementTypes.DIAGRAM_ID.equals(view.getType())) { - return DomainDiagramEditPart.class; - } - - Activator.log.error(new Exception("Could not create EditPart.")); - return null; - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramEditPolicyProvider.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramEditPolicyProvider.java deleted file mode 100644 index 59e2091914a..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramEditPolicyProvider.java +++ /dev/null @@ -1,155 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - -import org.eclipse.gef.EditPart; -import org.eclipse.gmf.runtime.common.core.service.AbstractProvider; -import org.eclipse.gmf.runtime.common.core.service.IOperation; -import org.eclipse.gmf.runtime.diagram.ui.editparts.GraphicalEditPart; -import org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles; -import org.eclipse.gmf.runtime.diagram.ui.services.editpolicy.CreateEditPoliciesOperation; -import org.eclipse.gmf.runtime.diagram.ui.services.editpolicy.IEditPolicyProvider; -import org.eclipse.papyrus.uml.diagram.domain.policies.CustomDragDropEditPolicy; - -public class DomainDiagramEditPolicyProvider extends AbstractProvider implements IEditPolicyProvider { - - public boolean provides(IOperation operation) { - - CreateEditPoliciesOperation epOperation = (CreateEditPoliciesOperation) operation; - if (!(epOperation.getEditPart() instanceof GraphicalEditPart)) { - return false; - } - GraphicalEditPart gep = (GraphicalEditPart) epOperation.getEditPart(); - String diagramType = gep.getNotationView().getDiagram().getType(); - if (!ElementTypes.DIAGRAM_ID.equals(diagramType)) { - return false; - } - - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PackageEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PackagePackageableElementCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PackageEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PackagePackageableElementCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.CommentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.CommentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ConstraintEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ConstraintEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.InstanceSpecificationEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.InstanceSpecificationSlotCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.InstanceSpecificationEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.InstanceSpecificationSlotCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassAttributeCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassOperationCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassNestedClassifierCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassAttributeCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassOperationCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.ClassNestedClassifierCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.DataTypeEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.DataTypeAttributeCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.DataTypeOperationCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.DataTypeEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.DataTypeAttributeCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.DataTypeOperationCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.EnumerationEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.EnumerationEnumerationLiteralCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.EnumerationEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.EnumerationEnumerationLiteralCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PrimitiveTypeEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PrimitiveTypeAttributeCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PrimitiveTypeOperationCompartmentEditPartCN) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PrimitiveTypeEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PrimitiveTypeAttributeCompartmentEditPart) { - return true; - } - if (gep instanceof org.eclipse.papyrus.uml.diagram.clazz.edit.parts.PrimitiveTypeOperationCompartmentEditPart) { - return true; - } - - return false; - } - - public void createEditPolicies(EditPart editPart) { - editPart.installEditPolicy(EditPolicyRoles.DRAG_DROP_ROLE, new CustomDragDropEditPolicy()); - } - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramViewProvider.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramViewProvider.java deleted file mode 100644 index 9ab84f7e6fa..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/DomainDiagramViewProvider.java +++ /dev/null @@ -1,43 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.gmf.runtime.diagram.core.providers.AbstractViewProvider; -import org.eclipse.gmf.runtime.diagram.core.services.view.CreateDiagramViewOperation; -import org.eclipse.papyrus.uml.diagram.domain.Activator; -import org.eclipse.papyrus.uml.diagram.domain.factory.DomainDiagramViewFactory; - -public class DomainDiagramViewProvider extends AbstractViewProvider { - - @Override - protected boolean provides(CreateDiagramViewOperation operation) { - - if (ElementTypes.DIAGRAM_ID.equals(operation.getSemanticHint())) { - return true; - } - - return false; - } - - @Override - protected Class<?> getDiagramViewClass(IAdaptable semanticAdapter, String diagramKind) { - if (ElementTypes.DIAGRAM_ID.equals(diagramKind)) { - return DomainDiagramViewFactory.class; - } - - Activator.log.error(new Exception("Could not create View.")); - return null; - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/ElementTypes.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/ElementTypes.java deleted file mode 100644 index b20b6292d67..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/ElementTypes.java +++ /dev/null @@ -1,225 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - -import org.eclipse.gmf.runtime.emf.type.core.AbstractElementTypeEnumerator; -import org.eclipse.gmf.runtime.emf.type.core.IHintedType; - -public class ElementTypes extends AbstractElementTypeEnumerator { - - /** ********************************************************* */ - /** UML Domain Diagram specific elements **************** */ - /** ********************************************************* */ - - /** UML Domain Diagram :: Diagram */ - public static final String DIAGRAM_ID = "domain"; //$NON-NLS-1$ - - - - - /** ********************************************************* */ - /** UML Domain Diagram - ClassDiagram related elements */ - /** ********************************************************* */ - - - /** ClassDiagram :: PACKAGE */ - public static final IHintedType PACKAGE = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Package_2007"); //$NON-NLS-1$ - - public static final String PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT = "7016"; //$NON-NLS-1$ - - public static final String PACKAGE_LABEL_NAME_HINT = "5026"; //$NON-NLS-1$ - - /** ClassDiagram :: PACKAGE_CN */ - public static final IHintedType PACKAGE_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Package_3009"); //$NON-NLS-1$ - - public static final String PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT = "7010"; //$NON-NLS-1$ - - public static final String PACKAGE_CN_LABEL_NAME_HINT = "5017"; //$NON-NLS-1$ - - /** ClassDiagram :: COMMENT */ - public static final IHintedType COMMENT = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Comment_2012"); //$NON-NLS-1$ - - public static final String COMMENT_LABEL_BODY_HINT = "5038"; //$NON-NLS-1$ - - /** ClassDiagram :: COMMENT_CN */ - public static final IHintedType COMMENT_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Comment_3028"); //$NON-NLS-1$ - - public static final String COMMENT_CN_LABEL_BODY_HINT = "5063"; //$NON-NLS-1$ - - /** ClassDiagram :: CONSTRAINT */ - public static final IHintedType CONSTRAINT = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Constraint_2011"); //$NON-NLS-1$ - - public static final String CONSTRAINT_LABEL_NAME_HINT = "5037"; //$NON-NLS-1$ - - public static final String CONSTRAINT_LABEL_BODY_HINT = "5159"; //$NON-NLS-1$ - - /** ClassDiagram :: CONSTRAINT_CN */ - public static final IHintedType CONSTRAINT_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Constraint_3029"); //$NON-NLS-1$ - - public static final String CONSTRAINT_CN_LABEL_NAME_HINT = "5064"; //$NON-NLS-1$ - - public static final String CONSTRAINT_CN_LABEL_BODY_HINT = "5160"; //$NON-NLS-1$ - - /** ClassDiagram :: INSTANCE_SPECIFICATION */ - public static final IHintedType INSTANCE_SPECIFICATION = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.InstanceSpecification_2001"); //$NON-NLS-1$ - - public static final String INSTANCE_SPECIFICATION_COMPARTMENT_SLOT_HINT = "7001"; //$NON-NLS-1$ - - public static final String INSTANCE_SPECIFICATION_LABEL_NAME_HINT = "5002"; //$NON-NLS-1$ - - /** ClassDiagram :: INSTANCE_SPECIFICATION_CN */ - public static final IHintedType INSTANCE_SPECIFICATION_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.InstanceSpecification_3020"); //$NON-NLS-1$ - - public static final String INSTANCE_SPECIFICATION_CN_COMPARTMENT_SLOT_HINT = "7035"; //$NON-NLS-1$ - - public static final String INSTANCE_SPECIFICATION_CN_LABEL_NAME_HINT = "5040"; //$NON-NLS-1$ - - /** ClassDiagram :: CLASS */ - public static final IHintedType CLASS = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Class_2008"); //$NON-NLS-1$ - - public static final String CLASS_COMPARTMENT_ATTRIBUTE_HINT = "7017"; //$NON-NLS-1$ - - public static final String CLASS_COMPARTMENT_OPERATION_HINT = "7018"; //$NON-NLS-1$ - - public static final String CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT = "7019"; //$NON-NLS-1$ - - public static final String CLASS_LABEL_NAME_HINT = "5029"; //$NON-NLS-1$ - - /** ClassDiagram :: CLASS_CN */ - public static final IHintedType CLASS_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Class_3010"); //$NON-NLS-1$ - - public static final String CLASS_CN_COMPARTMENT_ATTRIBUTE_HINT = "7011"; //$NON-NLS-1$ - - public static final String CLASS_CN_COMPARTMENT_OPERATION_HINT = "7012"; //$NON-NLS-1$ - - public static final String CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT = "7013"; //$NON-NLS-1$ - - public static final String CLASS_CN_LABEL_NAME_HINT = "5014"; //$NON-NLS-1$ - - /** ClassDiagram :: DATA_TYPE */ - public static final IHintedType DATA_TYPE = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.DataType_2010"); //$NON-NLS-1$ - - public static final String DATA_TYPE_COMPARTMENT_ATTRIBUTE_HINT = "7020"; //$NON-NLS-1$ - - public static final String DATA_TYPE_COMPARTMENT_OPERATION_HINT = "7021"; //$NON-NLS-1$ - - public static final String DATA_TYPE_LABEL_NAME_HINT = "5035"; //$NON-NLS-1$ - - /** ClassDiagram :: DATA_TYPE_CN */ - public static final IHintedType DATA_TYPE_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.DataType_3027"); //$NON-NLS-1$ - - public static final String DATA_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT = "7032"; //$NON-NLS-1$ - - public static final String DATA_TYPE_CN_COMPARTMENT_OPERATION_HINT = "7033"; //$NON-NLS-1$ - - public static final String DATA_TYPE_CN_LABEL_NAME_HINT = "5061"; //$NON-NLS-1$ - - /** ClassDiagram :: ENUMERATION */ - public static final IHintedType ENUMERATION = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Enumeration_2006"); //$NON-NLS-1$ - - public static final String ENUMERATION_COMPARTMENT_ENUMERATION_LITERAL_HINT = "7015"; //$NON-NLS-1$ - - public static final String ENUMERATION_LABEL_NAME_HINT = "5023"; //$NON-NLS-1$ - - /** ClassDiagram :: ENUMERATION_CN */ - public static final IHintedType ENUMERATION_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Enumeration_3025"); //$NON-NLS-1$ - - public static final String ENUMERATION_CN_COMPARTMENT_ENUMERATION_LITERAL_HINT = "7031"; //$NON-NLS-1$ - - public static final String ENUMERATION_CN_LABEL_NAME_HINT = "5055"; //$NON-NLS-1$ - - /** ClassDiagram :: PRIMITIVE_TYPE_CN */ - public static final IHintedType PRIMITIVE_TYPE_CN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.PrimitiveType_3026"); //$NON-NLS-1$ - - public static final String PRIMITIVE_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT = "7041"; //$NON-NLS-1$ - - public static final String PRIMITIVE_TYPE_CN_COMPARTMENT_OPERATION_HINT = "7042"; //$NON-NLS-1$ - - public static final String PRIMITIVE_TYPE_CN_LABEL_NAME_HINT = "5058"; //$NON-NLS-1$ - - /** ClassDiagram :: PRIMITIVE_TYPE */ - public static final IHintedType PRIMITIVE_TYPE = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.PrimitiveType_2009"); //$NON-NLS-1$ - - public static final String PRIMITIVE_TYPE_COMPARTMENT_ATTRIBUTE_HINT = "7039"; //$NON-NLS-1$ - - public static final String PRIMITIVE_TYPE_COMPARTMENT_OPERATION_HINT = "7040"; //$NON-NLS-1$ - - public static final String PRIMITIVE_TYPE_LABEL_NAME_HINT = "5032"; //$NON-NLS-1$ - - - /** ClassDiagram :: COMMENT_ANNOTATED_ELEMENT */ - public static final IHintedType COMMENT_ANNOTATED_ELEMENT = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.CommentAnnotatedElement_4013"); //$NON-NLS-1$ - - /** ClassDiagram :: CONSTRAINT_CONSTRAINED_ELEMENT */ - public static final IHintedType CONSTRAINT_CONSTRAINED_ELEMENT = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.ConstraintConstrainedElement_4014"); //$NON-NLS-1$ - - /** ClassDiagram :: GENERALIZATION */ - public static final IHintedType GENERALIZATION = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Generalization_4002"); //$NON-NLS-1$ - - public static final String GENERALIZATION_LABEL_APPLIED_STEREOTYPER_HINT = "6007"; //$NON-NLS-1$ - - /** ClassDiagram :: INSTANCE_SPECIFICATION */ - public static final IHintedType INSTANCE_SPECIFICATION_LINK = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.InstanceSpecificationLink_4021"); //$NON-NLS-1$ - - public static final String INSTANCE_SPECIFICATION_LABEL_SOURCE_IS_LINK_LABEL_HINT = "6039"; //$NON-NLS-1$ - - public static final String INSTANCE_SPECIFICATION_LABEL_TARGET_IS_LINK_LABEL_HINT = "6038"; //$NON-NLS-1$ - - /** ClassDiagram :: ASSOCIATION */ - public static final IHintedType ASSOCIATION = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Association_4001"); //$NON-NLS-1$ - - public static final String ASSOCIATION_LABEL_APPLIED_STEREOTYPE_HINT = "6001"; //$NON-NLS-1$ - - public static final String ASSOCIATION_LABEL_NAME_HINT = "6002"; //$NON-NLS-1$ - - public static final String ASSOCIATION_LABEL_TARGET_NAME_HINT = "6003"; //$NON-NLS-1$ - - public static final String ASSOCIATION_LABEL_SOURCE_NAME_HINT = "6005"; //$NON-NLS-1$ - - public static final String ASSOCIATION_LABEL_MULTIPLICITY_SOURCE_HINT = "6033"; //$NON-NLS-1$ - - public static final String ASSOCIATION_LABEL_MULTIPLICITY_TARGET_HINT = "6034"; //$NON-NLS-1$ - - /** ClassDiagram :: ChildLabelNodes */ - public static final IHintedType INSTANCE_SPECIFICATION_SLOT_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Slot_3030"); //$NON-NLS-1$ - - public static final IHintedType CLASS_PROPERTY_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Property_3012"); //$NON-NLS-1$ - - public static final IHintedType CLASS_RECEPTION_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Reception_3011"); //$NON-NLS-1$ - - public static final IHintedType CLASS_OPERATION_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Operation_3013"); //$NON-NLS-1$ - - public static final IHintedType CLASS_CLASS_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Class_3014"); //$NON-NLS-1$ - - public static final IHintedType CLASS_INTERFACE_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Interface_3036"); //$NON-NLS-1$ - - public static final IHintedType CLASS_ENUMERATION_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Enumeration_3052"); //$NON-NLS-1$ - - public static final IHintedType CLASS_PRIMITIVE_TYPE_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.PrimitiveType_3047"); //$NON-NLS-1$ - - public static final IHintedType CLASS_DATA_TYPE_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.DataType_3044"); //$NON-NLS-1$ - - public static final IHintedType CLASS_SIGNAL_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Signal_3050"); //$NON-NLS-1$ - - public static final IHintedType DATA_TYPE_PROPERTY_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Property_3018"); //$NON-NLS-1$ - - public static final IHintedType DATA_TYPE_OPERATION_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Operation_3019"); //$NON-NLS-1$ - - public static final IHintedType ENUMERATION_ENUMERATION_LITERAL_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.EnumerationLiteral_3017"); //$NON-NLS-1$ - - public static final IHintedType PRIMITIVE_TYPE_PROPERTY_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Property_3041"); //$NON-NLS-1$ - - public static final IHintedType PRIMITIVE_TYPE_OPERATION_CLN = (IHintedType) getElementType("org.eclipse.papyrus.uml.diagram.clazz.Operation_3042"); //$NON-NLS-1$ - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/GraphicalTypeRegistry.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/GraphicalTypeRegistry.java deleted file mode 100644 index a8c76273d36..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/GraphicalTypeRegistry.java +++ /dev/null @@ -1,400 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - -import java.util.HashSet; -import java.util.Set; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.gmf.runtime.emf.type.core.IElementType; -import org.eclipse.gmf.runtime.emf.type.core.IHintedType; -import org.eclipse.papyrus.infra.gmfdiag.common.providers.IGraphicalTypeRegistry; - -/** - * <pre> - * This class provides graphical type id (used as View type) for - * domain element according to their actual or expected graphical - * container type. - * </pre> - */ -public class GraphicalTypeRegistry implements IGraphicalTypeRegistry { - - /** A Set containing all known node graphical types */ - protected Set<String> knownNodes = new HashSet<String>(); - - /** A Set containing all known edge graphical types */ - protected Set<String> knownEdges = new HashSet<String>(); - - /** Default constructor */ - public GraphicalTypeRegistry() { - - // Fill known edges set - knownEdges.add(ElementTypes.GENERALIZATION.getSemanticHint()); - knownEdges.add(ElementTypes.INSTANCE_SPECIFICATION_LINK.getSemanticHint()); - knownEdges.add(ElementTypes.ASSOCIATION.getSemanticHint()); - knownEdges.add(ElementTypes.COMMENT_ANNOTATED_ELEMENT.getSemanticHint()); - knownEdges.add(ElementTypes.CONSTRAINT_CONSTRAINED_ELEMENT.getSemanticHint()); - - // Fill known nodes set (primary nodes) - knownNodes.add(ElementTypes.PACKAGE.getSemanticHint()); - knownNodes.add(ElementTypes.PACKAGE_CN.getSemanticHint()); - knownNodes.add(ElementTypes.COMMENT.getSemanticHint()); - knownNodes.add(ElementTypes.COMMENT_CN.getSemanticHint()); - knownNodes.add(ElementTypes.CONSTRAINT.getSemanticHint()); - knownNodes.add(ElementTypes.CONSTRAINT_CN.getSemanticHint()); - knownNodes.add(ElementTypes.INSTANCE_SPECIFICATION.getSemanticHint()); - knownNodes.add(ElementTypes.INSTANCE_SPECIFICATION_CN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_CN.getSemanticHint()); - knownNodes.add(ElementTypes.DATA_TYPE.getSemanticHint()); - knownNodes.add(ElementTypes.DATA_TYPE_CN.getSemanticHint()); - knownNodes.add(ElementTypes.ENUMERATION.getSemanticHint()); - knownNodes.add(ElementTypes.ENUMERATION_CN.getSemanticHint()); - knownNodes.add(ElementTypes.PRIMITIVE_TYPE_CN.getSemanticHint()); - knownNodes.add(ElementTypes.PRIMITIVE_TYPE.getSemanticHint()); - - // Fill known nodes set (child label nodes) - knownNodes.add(ElementTypes.INSTANCE_SPECIFICATION_SLOT_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_PROPERTY_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_RECEPTION_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_OPERATION_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_CLASS_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_INTERFACE_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_ENUMERATION_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_PRIMITIVE_TYPE_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_DATA_TYPE_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.CLASS_SIGNAL_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.DATA_TYPE_PROPERTY_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.DATA_TYPE_OPERATION_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.ENUMERATION_ENUMERATION_LITERAL_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.PRIMITIVE_TYPE_PROPERTY_CLN.getSemanticHint()); - knownNodes.add(ElementTypes.PRIMITIVE_TYPE_OPERATION_CLN.getSemanticHint()); - } - - /** - * {@inheritDoc} - */ - public String getEdgeGraphicalType(EObject domainElement) { - - String graphicalType = UNDEFINED_TYPE; - if (domainElement == null) { - return UNDEFINED_TYPE; - } - if (domainElement instanceof org.eclipse.uml2.uml.Generalization) { - graphicalType = ElementTypes.GENERALIZATION.getSemanticHint(); - } - if (domainElement instanceof org.eclipse.uml2.uml.InstanceSpecification) { - graphicalType = ElementTypes.INSTANCE_SPECIFICATION.getSemanticHint(); - } - if (domainElement instanceof org.eclipse.uml2.uml.Association) { - graphicalType = ElementTypes.ASSOCIATION.getSemanticHint(); - } - return graphicalType; - } - - /** - * {@inheritDoc} - */ - public String getEdgeGraphicalType(IElementType elementType) { - if (elementType instanceof IHintedType) { - String semanticHint = ((IHintedType) elementType).getSemanticHint(); - return getEdgeGraphicalType(semanticHint); - } - - return UNDEFINED_TYPE; - } - - /** - * {@inheritDoc} - */ - public String getEdgeGraphicalType(String proposedType) { - if (isKnownEdgeType(proposedType)) { - return proposedType; - } - - return UNDEFINED_TYPE; - } - - /** - * {@inheritDoc} - */ - public String getNodeGraphicalType(EObject domainElement, String containerType) { - - String graphicalType = UNDEFINED_TYPE; - if ((containerType == null) || (domainElement == null)) { - return UNDEFINED_TYPE; - } - - if (domainElement instanceof org.eclipse.uml2.uml.Package) { - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // Package TopNode - graphicalType = ElementTypes.PACKAGE.getSemanticHint(); - } - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Package ChildNode - graphicalType = ElementTypes.PACKAGE_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Package ChildNode - graphicalType = ElementTypes.PACKAGE_CN.getSemanticHint(); - } - - } - - if (domainElement instanceof org.eclipse.uml2.uml.Comment) { - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // Comment TopNode - graphicalType = ElementTypes.COMMENT.getSemanticHint(); - } - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Comment ChildNode - graphicalType = ElementTypes.COMMENT_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Comment ChildNode - graphicalType = ElementTypes.COMMENT_CN.getSemanticHint(); - } - - } - - if (domainElement instanceof org.eclipse.uml2.uml.Constraint) { - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // Constraint TopNode - graphicalType = ElementTypes.CONSTRAINT.getSemanticHint(); - } - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Constraint ChildNode - graphicalType = ElementTypes.CONSTRAINT_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Constraint ChildNode - graphicalType = ElementTypes.CONSTRAINT_CN.getSemanticHint(); - } - - } - - if (domainElement instanceof org.eclipse.uml2.uml.InstanceSpecification) { - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // InstanceSpecification TopNode - graphicalType = ElementTypes.INSTANCE_SPECIFICATION.getSemanticHint(); - } - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // InstanceSpecification ChildNode - graphicalType = ElementTypes.INSTANCE_SPECIFICATION_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // InstanceSpecification ChildNode - graphicalType = ElementTypes.INSTANCE_SPECIFICATION_CN.getSemanticHint(); - } - - } - - if (domainElement instanceof org.eclipse.uml2.uml.Class) { - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // Class TopNode - graphicalType = ElementTypes.CLASS.getSemanticHint(); - } - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Class ChildNode - graphicalType = ElementTypes.CLASS_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Class ChildNode - graphicalType = ElementTypes.CLASS_CN.getSemanticHint(); - } - - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Class ChildLabelNode - graphicalType = ElementTypes.CLASS_CLASS_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Class ChildLabelNode - graphicalType = ElementTypes.CLASS_CLASS_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.DataType) { - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // DataType TopNode - graphicalType = ElementTypes.DATA_TYPE.getSemanticHint(); - } - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // DataType ChildNode - graphicalType = ElementTypes.DATA_TYPE_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // DataType ChildNode - graphicalType = ElementTypes.DATA_TYPE_CN.getSemanticHint(); - } - - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // DataType ChildLabelNode - graphicalType = ElementTypes.CLASS_DATA_TYPE_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // DataType ChildLabelNode - graphicalType = ElementTypes.CLASS_DATA_TYPE_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.Enumeration) { - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // Enumeration TopNode - graphicalType = ElementTypes.ENUMERATION.getSemanticHint(); - } - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Enumeration ChildNode - graphicalType = ElementTypes.ENUMERATION_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // Enumeration ChildNode - graphicalType = ElementTypes.ENUMERATION_CN.getSemanticHint(); - } - - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Enumeration ChildLabelNode - graphicalType = ElementTypes.CLASS_ENUMERATION_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Enumeration ChildLabelNode - graphicalType = ElementTypes.CLASS_ENUMERATION_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.PrimitiveType) { - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // PrimitiveType ChildNode - graphicalType = ElementTypes.PRIMITIVE_TYPE_CN.getSemanticHint(); - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerType)) { // PrimitiveType ChildNode - graphicalType = ElementTypes.PRIMITIVE_TYPE_CN.getSemanticHint(); - } - if (ElementTypes.DIAGRAM_ID.equals(containerType)) { // PrimitiveType TopNode - graphicalType = ElementTypes.PRIMITIVE_TYPE.getSemanticHint(); - } - - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // PrimitiveType ChildLabelNode - graphicalType = ElementTypes.CLASS_PRIMITIVE_TYPE_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // PrimitiveType ChildLabelNode - graphicalType = ElementTypes.CLASS_PRIMITIVE_TYPE_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.Slot) { - - if (ElementTypes.INSTANCE_SPECIFICATION_COMPARTMENT_SLOT_HINT.equals(containerType)) { // Slot ChildLabelNode - graphicalType = ElementTypes.INSTANCE_SPECIFICATION_SLOT_CLN.getSemanticHint(); - } - if (ElementTypes.INSTANCE_SPECIFICATION_CN_COMPARTMENT_SLOT_HINT.equals(containerType)) { // Slot ChildLabelNode - graphicalType = ElementTypes.INSTANCE_SPECIFICATION_SLOT_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.Property) { - - if (ElementTypes.CLASS_COMPARTMENT_ATTRIBUTE_HINT.equals(containerType)) { // Property ChildLabelNode - graphicalType = ElementTypes.CLASS_PROPERTY_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_CN_COMPARTMENT_ATTRIBUTE_HINT.equals(containerType)) { // Property ChildLabelNode - graphicalType = ElementTypes.CLASS_PROPERTY_CLN.getSemanticHint(); - } - if (ElementTypes.DATA_TYPE_COMPARTMENT_ATTRIBUTE_HINT.equals(containerType)) { // Property ChildLabelNode - graphicalType = ElementTypes.DATA_TYPE_PROPERTY_CLN.getSemanticHint(); - } - if (ElementTypes.DATA_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT.equals(containerType)) { // Property ChildLabelNode - graphicalType = ElementTypes.DATA_TYPE_PROPERTY_CLN.getSemanticHint(); - } - if (ElementTypes.PRIMITIVE_TYPE_COMPARTMENT_ATTRIBUTE_HINT.equals(containerType)) { // Property ChildLabelNode - graphicalType = ElementTypes.PRIMITIVE_TYPE_PROPERTY_CLN.getSemanticHint(); - } - if (ElementTypes.PRIMITIVE_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT.equals(containerType)) { // Property ChildLabelNode - graphicalType = ElementTypes.PRIMITIVE_TYPE_PROPERTY_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.Reception) { - - if (ElementTypes.CLASS_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Reception ChildLabelNode - graphicalType = ElementTypes.CLASS_RECEPTION_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_CN_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Reception ChildLabelNode - graphicalType = ElementTypes.CLASS_RECEPTION_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.Operation) { - - if (ElementTypes.CLASS_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Operation ChildLabelNode - graphicalType = ElementTypes.CLASS_OPERATION_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_CN_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Operation ChildLabelNode - graphicalType = ElementTypes.CLASS_OPERATION_CLN.getSemanticHint(); - } - if (ElementTypes.DATA_TYPE_CN_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Operation ChildLabelNode - graphicalType = ElementTypes.DATA_TYPE_OPERATION_CLN.getSemanticHint(); - } - if (ElementTypes.DATA_TYPE_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Operation ChildLabelNode - graphicalType = ElementTypes.DATA_TYPE_OPERATION_CLN.getSemanticHint(); - } - if (ElementTypes.PRIMITIVE_TYPE_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Operation ChildLabelNode - graphicalType = ElementTypes.PRIMITIVE_TYPE_OPERATION_CLN.getSemanticHint(); - } - if (ElementTypes.PRIMITIVE_TYPE_CN_COMPARTMENT_OPERATION_HINT.equals(containerType)) { // Operation ChildLabelNode - graphicalType = ElementTypes.PRIMITIVE_TYPE_OPERATION_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.Interface) { - - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Interface ChildLabelNode - graphicalType = ElementTypes.CLASS_INTERFACE_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Interface ChildLabelNode - graphicalType = ElementTypes.CLASS_INTERFACE_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.Signal) { - - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Signal ChildLabelNode - graphicalType = ElementTypes.CLASS_SIGNAL_CLN.getSemanticHint(); - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerType)) { // Signal ChildLabelNode - graphicalType = ElementTypes.CLASS_SIGNAL_CLN.getSemanticHint(); - } - } - - if (domainElement instanceof org.eclipse.uml2.uml.EnumerationLiteral) { - - if (ElementTypes.ENUMERATION_CN_COMPARTMENT_ENUMERATION_LITERAL_HINT.equals(containerType)) { // EnumerationLiteral ChildLabelNode - graphicalType = ElementTypes.ENUMERATION_ENUMERATION_LITERAL_CLN.getSemanticHint(); - } - if (ElementTypes.ENUMERATION_COMPARTMENT_ENUMERATION_LITERAL_HINT.equals(containerType)) { // EnumerationLiteral ChildLabelNode - graphicalType = ElementTypes.ENUMERATION_ENUMERATION_LITERAL_CLN.getSemanticHint(); - } - } - - return graphicalType; - } - - /** - * {@inheritDoc} - */ - public String getNodeGraphicalType(IElementType elementType, String containerType) { - if (elementType instanceof IHintedType) { - String semanticHint = ((IHintedType) elementType).getSemanticHint(); - return getNodeGraphicalType(semanticHint, containerType); - } - - return UNDEFINED_TYPE; - } - - /** - * {@inheritDoc} - */ - public String getNodeGraphicalType(String proposedType, String containerType) { - if (isKnownNodeType(proposedType)) { - return proposedType; - } - - return UNDEFINED_TYPE; - } - - /** - * {@inheritDoc} - */ - public boolean isKnownEdgeType(String type) { - return knownEdges.contains(type); - } - - /** - * {@inheritDoc} - */ - public boolean isKnownNodeType(String type) { - return knownNodes.contains(type); - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/IGraphicalTypeRegistry.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/IGraphicalTypeRegistry.java deleted file mode 100644 index 6dd4bbd64dd..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/IGraphicalTypeRegistry.java +++ /dev/null @@ -1,110 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.gmf.runtime.emf.type.core.IElementType; - -/** - * This interface provides an API for accessing the local graphical type registry. - * This registry provides a graphical type for existing model elements. - */ -public interface IGraphicalTypeRegistry { - - /** Constant for undefined graphical type */ - public static final String UNDEFINED_TYPE = "undefined_type"; - - /** - * Get a valid edge graphical type for the domain element. - * - * @param domainElement - * the domain element. - * @return the domain element graphical type. - */ - public String getEdgeGraphicalType(EObject domainElement); - - /** - * Get a valid edge graphical type for the element type. - * - * @param elementType - * the element type. - * @param containerType - * the type of the graphical owner of the domain element. - * @return the domain element graphical type. - */ - public String getEdgeGraphicalType(IElementType elementType); - - /** - * Get a valid edge graphical type for the proposed type. - * - * @param proposedType - * the proposed type. - * @param containerType - * the type of the graphical owner of the domain element. - * @return the domain element graphical type. - */ - public String getEdgeGraphicalType(String proposedType); - - /** - * Get a valid node graphical type for the domain element. - * - * @param domainElement - * the domain element. - * @param containerType - * the type of the graphical owner of the domain element. - * @return the domain element graphical type. - */ - public String getNodeGraphicalType(EObject domainElement, String containerType); - - /** - * Get a valid node graphical type for the element type. - * - * @param elementType - * the element type. - * @param containerType - * the type of the graphical owner of the domain element. - * @return the domain element graphical type. - */ - public String getNodeGraphicalType(IElementType elementType, String containerType); - - /** - * Get a valid node graphical type for the proposed type. - * - * @param proposedType - * the proposed type. - * @param containerType - * the type of the graphical owner of the domain element. - * @return the domain element graphical type. - */ - public String getNodeGraphicalType(String proposedType, String containerType); - - /** - * Test if the type is a known edge graphical type in this diagram - * - * @param type - * the type to test - * @return true if the type is known - */ - public boolean isKnownEdgeType(String type); - - /** - * Test if the type is a known node graphical type in this diagram - * - * @param type - * the type to test - * @return true if the type is known - */ - public boolean isKnownNodeType(String type); - -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/InheritedClassDiagramEditPartProvider.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/InheritedClassDiagramEditPartProvider.java deleted file mode 100644 index ccb871f9a37..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/InheritedClassDiagramEditPartProvider.java +++ /dev/null @@ -1,116 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.gmf.runtime.common.core.service.IOperation; -import org.eclipse.gmf.runtime.diagram.ui.services.editpart.CreateGraphicEditPartOperation; -import org.eclipse.gmf.runtime.diagram.ui.services.editpart.IEditPartOperation; -import org.eclipse.gmf.runtime.notation.View; -import org.eclipse.papyrus.uml.diagram.clazz.providers.UMLEditPartProvider; - -public class InheritedClassDiagramEditPartProvider extends UMLEditPartProvider { - - @Override - public synchronized boolean provides(IOperation operation) { - if (operation instanceof CreateGraphicEditPartOperation) { - View view = ((IEditPartOperation) operation).getView(); - - // Ensure current diagram is a Domain Diagram - if (!ElementTypes.DIAGRAM_ID.equals(view.getDiagram().getType())) { - return false; - } - - // Test supported inherited types - EObject eobject = view.getElement(); - - /** Nodes (and ChildLabelNodes) *********** */ - if (eobject instanceof org.eclipse.uml2.uml.Package) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Comment) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Constraint) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.InstanceSpecification) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Class) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.DataType) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Enumeration) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.PrimitiveType) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Slot) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Property) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Reception) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Operation) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Interface) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Signal) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.EnumerationLiteral) { - return true; - } - - /** Edges *********** */ - if (eobject instanceof org.eclipse.uml2.uml.Generalization) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.InstanceSpecification) { - return true; - } - if (eobject instanceof org.eclipse.uml2.uml.Association) { - return true; - } - - // Additional test needed here to decide whether to support Feature type links. - // As feature type link are not related to a MetaClass from the domain model - // they are not already handled by previous tests. - // Also concerns NotationType. - String hint = view.getType(); - - /** Edges (Feature) : COMMENT_ANNOTATED_ELEMENT *********** */ - if (ElementTypes.COMMENT_ANNOTATED_ELEMENT.getSemanticHint().equals(hint)) { - return true; - } - /** Edges (Feature) : CONSTRAINT_CONSTRAINED_ELEMENT *********** */ - if (ElementTypes.CONSTRAINT_CONSTRAINED_ELEMENT.getSemanticHint().equals(hint)) { - return true; - } - - - - } - return false; - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/InheritedClassDiagramViewProvider.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/InheritedClassDiagramViewProvider.java deleted file mode 100644 index 93fd42c2e7c..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src-gen/org/eclipse/papyrus/uml/diagram/domain/provider/InheritedClassDiagramViewProvider.java +++ /dev/null @@ -1,543 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2011 CEA LIST. - * - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * - * CEA LIST - Initial API and implementation - * - *****************************************************************************/ -package org.eclipse.papyrus.uml.diagram.domain.provider; - - -import org.eclipse.core.runtime.IAdaptable; -import org.eclipse.emf.ecore.EAnnotation; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EcoreFactory; -import org.eclipse.gmf.runtime.diagram.core.preferences.PreferencesHint; -import org.eclipse.gmf.runtime.diagram.core.services.view.CreateEdgeViewOperation; -import org.eclipse.gmf.runtime.diagram.core.services.view.CreateNodeViewOperation; -import org.eclipse.gmf.runtime.diagram.core.services.view.CreateViewForKindOperation; -import org.eclipse.gmf.runtime.emf.type.core.IElementType; -import org.eclipse.gmf.runtime.notation.Edge; -import org.eclipse.gmf.runtime.notation.Node; -import org.eclipse.gmf.runtime.notation.View; -import org.eclipse.papyrus.infra.gmfdiag.common.providers.IGraphicalTypeRegistry; -import org.eclipse.papyrus.uml.diagram.clazz.providers.UMLViewProvider; -import org.eclipse.papyrus.uml.diagram.domain.Activator; - -public class InheritedClassDiagramViewProvider extends UMLViewProvider { - - /** Local graphical type registry */ - protected IGraphicalTypeRegistry registry = new GraphicalTypeRegistry(); - - @Override - public Edge createEdge(IAdaptable semanticAdapter, View containerView, String semanticHint, int index, boolean persisted, PreferencesHint preferencesHint) { - Edge createdEdge = null; - - IElementType elementType = (IElementType) semanticAdapter.getAdapter(IElementType.class); - if (elementType != null) { - createdEdge = super.createEdge(semanticAdapter, containerView, semanticHint, index, persisted, preferencesHint); - } else { - - EObject domainElement = (EObject) semanticAdapter.getAdapter(EObject.class); - - String domainElementGraphicalType = semanticHint; - if (domainElementGraphicalType == null) { - domainElementGraphicalType = registry.getEdgeGraphicalType(domainElement); - } - - if ((!IGraphicalTypeRegistry.UNDEFINED_TYPE.equals(domainElementGraphicalType)) && (registry.isKnownEdgeType(domainElementGraphicalType))) { - // Cannot use createEdge from super class as it never take the graphical type (semanticHint) into account. - // createdEdge = super.createEdge(semanticAdapter, containerView, domainElementGraphicalType, index, persisted, preferencesHint); - - if (ElementTypes.COMMENT_ANNOTATED_ELEMENT.getSemanticHint().equals(domainElementGraphicalType)) { - createdEdge = createCommentAnnotatedElement_4013(containerView, index, persisted, preferencesHint); - } - if (ElementTypes.CONSTRAINT_CONSTRAINED_ELEMENT.getSemanticHint().equals(domainElementGraphicalType)) { - createdEdge = createConstraintConstrainedElement_4014(containerView, index, persisted, preferencesHint); - } - if (ElementTypes.GENERALIZATION.getSemanticHint().equals(domainElementGraphicalType)) { - createdEdge = createGeneralization_4002(domainElement, containerView, index, persisted, preferencesHint); - } - if (ElementTypes.INSTANCE_SPECIFICATION_LINK.getSemanticHint().equals(domainElementGraphicalType)) { - createdEdge = createInstanceSpecification_4021(domainElement, containerView, index, persisted, preferencesHint); - } - if (ElementTypes.ASSOCIATION.getSemanticHint().equals(domainElementGraphicalType)) { - createdEdge = createAssociation_4001(domainElement, containerView, index, persisted, preferencesHint); - } - } - } - - if (createdEdge == null) { - Activator.log.error(new Exception("Could not create Edge.")); - } - - return createdEdge; - } - - @Override - protected boolean provides(CreateViewForKindOperation op) { - - // This provider is registered for Domain Diagram only - String diagramType = op.getContainerView().getDiagram().getType(); - if (!ElementTypes.DIAGRAM_ID.equals(diagramType)) { - return false; - } - - return true; - } - - @Override - protected boolean provides(CreateEdgeViewOperation op) { - - // Must have a container - if (op.getContainerView() == null) { - return false; - } - - // This provider is registered for Domain Diagram only - String diagramType = op.getContainerView().getDiagram().getType(); - if (!ElementTypes.DIAGRAM_ID.equals(diagramType)) { - return false; - } - - IElementType elementType = getSemanticElementType(op.getSemanticAdapter()); - if (elementType == ElementTypes.COMMENT_ANNOTATED_ELEMENT) { - return true; - } - if (elementType == ElementTypes.CONSTRAINT_CONSTRAINED_ELEMENT) { - return true; - } - if (elementType == ElementTypes.GENERALIZATION) { - return true; - } - if (elementType == ElementTypes.INSTANCE_SPECIFICATION) { - return true; - } - if (elementType == ElementTypes.ASSOCIATION) { - return true; - } - - // ///////////////////////////////////////////////////////////////////// - // Test possibility to provide a view based on the semantic nature and its expected container. - // ///////////////////////////////////////////////////////////////////// - - // IElementType may be null (especially when drop from ModelExplorer). - // In such a case, test the semantic EObject instead. - if (elementType == null) { - EObject domainElement = (EObject) op.getSemanticAdapter().getAdapter(EObject.class); - String domainElementGraphicalType = op.getSemanticHint(); - if (domainElementGraphicalType == null) { - domainElementGraphicalType = registry.getEdgeGraphicalType(domainElement); - } - - if ((!IGraphicalTypeRegistry.UNDEFINED_TYPE.equals(domainElementGraphicalType)) && (registry.isKnownEdgeType(domainElementGraphicalType))) { - return true; - } - } - - return false; - } - - @Override - protected boolean provides(CreateNodeViewOperation op) { - // Must have a container - if (op.getContainerView() == null) { - return false; - } - // Get the type of the container - String containerGraphicalType = op.getContainerView().getType(); - - // This provider is registered for Domain Diagram only - String diagramType = op.getContainerView().getDiagram().getType(); - if (!ElementTypes.DIAGRAM_ID.equals(diagramType)) { - return false; - } - - // ///////////////////////////////////////////////////////////////////// - // Test possibility to provide a view based on the ElementType and its expected container. - // ///////////////////////////////////////////////////////////////////// - - IElementType elementType = (IElementType) op.getSemanticAdapter().getAdapter(IElementType.class); - if (elementType == ElementTypes.PACKAGE) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.PACKAGE_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@5755829a (visualID: 3009, editPartClassName: PackageEditPartCN, itemSemanticEditPolicyClassName: PackageItemSemanticEditPolicyCN, notationViewFactoryClassName: null) - // (canonicalEditPolicyClassName: PackageCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: PackageGraphicalNodeEditPolicyCN, createCommandClassName: PackageCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@143f35fb (name: null) (customPreferencePage: , generatePreferencePage: false, generateTool: false) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.COMMENT) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.COMMENT_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@6c08e2a (visualID: 3028, editPartClassName: CommentEditPartCN, itemSemanticEditPolicyClassName: CommentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) - // (canonicalEditPolicyClassName: CommentCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: CommentGraphicalNodeEditPolicyCN, createCommandClassName: CommentCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@3438790b (name: null) (customPreferencePage: null, generatePreferencePage: false, generateTool: false) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CONSTRAINT) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CONSTRAINT_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@750b223e (visualID: 3029, editPartClassName: ConstraintEditPartCN, itemSemanticEditPolicyClassName: ConstraintItemSemanticEditPolicyCN, notationViewFactoryClassName: null) - // (canonicalEditPolicyClassName: ConstraintCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: ConstraintGraphicalNodeEditPolicyCN, createCommandClassName: ConstraintCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@5aa6e6f2 (name: null) (customPreferencePage: null, generatePreferencePage: false, generateTool: false) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.INSTANCE_SPECIFICATION) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.INSTANCE_SPECIFICATION_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@1af04081 (visualID: 3020, editPartClassName: InstanceSpecificationEditPartCN, itemSemanticEditPolicyClassName: InstanceSpecificationItemSemanticEditPolicyCN, - // notationViewFactoryClassName: null) (canonicalEditPolicyClassName: InstanceSpecificationCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: InstanceSpecificationGraphicalNodeEditPolicyCN, - // createCommandClassName: InstanceSpecificationCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@61aad378 (name: null) (customPreferencePage: null, generatePreferencePage: false, generateTool: false) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@6b5d9eb1 (visualID: 3010, editPartClassName: ClassEditPartCN, itemSemanticEditPolicyClassName: ClassItemSemanticEditPolicyCN, notationViewFactoryClassName: null) - // (canonicalEditPolicyClassName: ClassCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: ClassGraphicalNodeEditPolicyCN, createCommandClassName: ClassCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@78e314f9 (name: null) (customPreferencePage: null, generatePreferencePage: false, generateTool: false) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.DATA_TYPE) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.DATA_TYPE_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@2a94e952 (visualID: 3027, editPartClassName: DataTypeEditPartCN, itemSemanticEditPolicyClassName: DataTypeItemSemanticEditPolicyCN, notationViewFactoryClassName: null) - // (canonicalEditPolicyClassName: DataTypeCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: DataTypeGraphicalNodeEditPolicyCN, createCommandClassName: DataTypeCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@6893de59 (name: null) (customPreferencePage: null, generatePreferencePage: false, generateTool: false) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.ENUMERATION) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.ENUMERATION_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@3ab2d76 (visualID: 3025, editPartClassName: EnumerationEditPartCN, itemSemanticEditPolicyClassName: EnumerationItemSemanticEditPolicyCN, notationViewFactoryClassName: null) - // (canonicalEditPolicyClassName: EnumerationCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: EnumerationGraphicalNodeEditPolicyCN, createCommandClassName: EnumerationCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@6fbbfef3 (name: null) (customPreferencePage: null, generatePreferencePage: true, generateTool: true) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.PRIMITIVE_TYPE_CN) { - // node: org.eclipse.gmf.codegen.gmfgen.impl.GenChildNodeImpl@60c476cd (visualID: 3026, editPartClassName: PrimitiveTypeEditPartCN, itemSemanticEditPolicyClassName: PrimitiveTypeItemSemanticEditPolicyCN, notationViewFactoryClassName: null) - // (canonicalEditPolicyClassName: PrimitiveTypeCanonicalEditPolicyCN) (primaryDragEditPolicyQualifiedClassName: null, graphicalNodeEditPolicyClassName: PrimitiveTypeGraphicalNodeEditPolicyCN, createCommandClassName: PrimitiveTypeCreateCommandCN) - // containers: org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@6f4fb27a (visualID: 7010, editPartClassName: PackagePackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: - // false, hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@42bb5c7d (visualID: 7009, editPartClassName: ModelPackageableElementCompartmentEditPartTN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyTN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyTN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@1ab534c5 (visualID: 7030, editPartClassName: ModelPackageableElementCompartmentEditPartCN, itemSemanticEditPolicyClassName: - // ModelPackageableElementCompartmentItemSemanticEditPolicyCN, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: ModelPackageableElementCompartmentCanonicalEditPolicyCN) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false)org.eclipse.gmf.codegen.gmfgen.impl.GenCompartmentImpl@5f946847 (visualID: 7016, editPartClassName: PackagePackageableElementCompartmentEditPart, itemSemanticEditPolicyClassName: - // PackagePackageableElementCompartmentItemSemanticEditPolicy, notationViewFactoryClassName: null) (canonicalEditPolicyClassName: PackagePackageableElementCompartmentCanonicalEditPolicy) (title: PackageableElementCompartment, canCollapse: false, - // hideIfEmpty: true, needsTitle: true, listLayout: false) - // nodeRef: org.eclipse.papyrus.generation.diagram.idgen.impl.GenNodeRefImpl@1f5f3cd4 (name: null) (customPreferencePage: null, generatePreferencePage: true, generateTool: true) - if (ElementTypes.PACKAGE_CN_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PACKAGE_COMPARTMENT_PACKAGEABLE_ELEMENT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.PRIMITIVE_TYPE) { - if (ElementTypes.DIAGRAM_ID.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.INSTANCE_SPECIFICATION_SLOT_CLN) { - if (ElementTypes.INSTANCE_SPECIFICATION_COMPARTMENT_SLOT_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.INSTANCE_SPECIFICATION_CN_COMPARTMENT_SLOT_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_PROPERTY_CLN) { - if (ElementTypes.CLASS_COMPARTMENT_ATTRIBUTE_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_CN_COMPARTMENT_ATTRIBUTE_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_RECEPTION_CLN) { - if (ElementTypes.CLASS_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_CN_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_OPERATION_CLN) { - if (ElementTypes.CLASS_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_CN_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_CLASS_CLN) { - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_INTERFACE_CLN) { - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_ENUMERATION_CLN) { - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_PRIMITIVE_TYPE_CLN) { - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_DATA_TYPE_CLN) { - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.CLASS_SIGNAL_CLN) { - if (ElementTypes.CLASS_CN_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.CLASS_COMPARTMENT_NESTED_CLASSIFIER_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.DATA_TYPE_PROPERTY_CLN) { - if (ElementTypes.DATA_TYPE_COMPARTMENT_ATTRIBUTE_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.DATA_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.DATA_TYPE_OPERATION_CLN) { - if (ElementTypes.DATA_TYPE_CN_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.DATA_TYPE_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.ENUMERATION_ENUMERATION_LITERAL_CLN) { - if (ElementTypes.ENUMERATION_CN_COMPARTMENT_ENUMERATION_LITERAL_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.ENUMERATION_COMPARTMENT_ENUMERATION_LITERAL_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.PRIMITIVE_TYPE_PROPERTY_CLN) { - if (ElementTypes.PRIMITIVE_TYPE_COMPARTMENT_ATTRIBUTE_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PRIMITIVE_TYPE_CN_COMPARTMENT_ATTRIBUTE_HINT.equals(containerGraphicalType)) { - return true; - } - } - if (elementType == ElementTypes.PRIMITIVE_TYPE_OPERATION_CLN) { - if (ElementTypes.PRIMITIVE_TYPE_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - if (ElementTypes.PRIMITIVE_TYPE_CN_COMPARTMENT_OPERATION_HINT.equals(containerGraphicalType)) { - return true; - } - } - - // ///////////////////////////////////////////////////////////////////// - // Test possibility to provide a view based on the semantic nature and its expected container. - // ///////////////////////////////////////////////////////////////////// - - // IElementType may be null (especially when drop from ModelExplorer). - // In such a case, test the semantic EObject instead. - if (elementType == null) { - EObject domainElement = (EObject) op.getSemanticAdapter().getAdapter(EObject.class); - String domainElementGraphicalType = op.getSemanticHint(); - if (domainElementGraphicalType == null) { - domainElementGraphicalType = registry.getNodeGraphicalType(domainElement, containerGraphicalType); - } else { - domainElementGraphicalType = registry.getNodeGraphicalType(domainElementGraphicalType, containerGraphicalType); - } - - if ((!IGraphicalTypeRegistry.UNDEFINED_TYPE.equals(domainElementGraphicalType)) && (registry.isKnownNodeType(domainElementGraphicalType))) { - return true; - } - } - return false; - } - - @Override - public Node createNode(IAdaptable semanticAdapter, View containerView, String semanticHint, int index, boolean persisted, PreferencesHint preferencesHint) { - - if (semanticHint != null) { - return super.createNode(semanticAdapter, containerView, semanticHint, index, persisted, preferencesHint); - } - - // Use the GraphicalTypeRegistry to find the expected type for a domain element - // Get the type of the container - String containerGraphicalType = containerView.getType(); - // Get the type of the domain element - EObject domainElement = (EObject) semanticAdapter.getAdapter(EObject.class); - String domainElementGraphicalType = registry.getNodeGraphicalType(domainElement, containerGraphicalType); - - // Create the expected node - if (!IGraphicalTypeRegistry.UNDEFINED_TYPE.equals(domainElementGraphicalType)) { - return super.createNode(semanticAdapter, containerView, domainElementGraphicalType, index, persisted, preferencesHint); - } - - Activator.log.error(new Exception("Could not create Node.")); - return null; - } - - @Override - protected void stampShortcut(View containerView, Node target) { - if (!ElementTypes.DIAGRAM_ID.equals(containerView.getDiagram().getType())) { - EAnnotation shortcutAnnotation = EcoreFactory.eINSTANCE.createEAnnotation(); - shortcutAnnotation.setSource("Shortcut"); //$NON-NLS-1$ - shortcutAnnotation.getDetails().put("modelID", ElementTypes.DIAGRAM_ID); //$NON-NLS-1$ - target.getEAnnotations().add(shortcutAnnotation); - } - } -} diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src/org/eclipse/papyrus/uml/diagram/domain/command/CreateDomainModelCommand.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src/org/eclipse/papyrus/uml/diagram/domain/command/CreateDomainModelCommand.java deleted file mode 100644 index db563df9005..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src/org/eclipse/papyrus/uml/diagram/domain/command/CreateDomainModelCommand.java +++ /dev/null @@ -1,58 +0,0 @@ -/*****************************************************************************
- * Copyright (c) 2010 CEA LIST.
- *
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Tatiana Fesenko (CEA LIST) - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.diagram.domain.command;
-
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.papyrus.uml.diagram.common.commands.ModelCreationCommandBase;
-import org.eclipse.uml2.uml.UMLFactory;
-
-/**
- * The Class CreateUMLModelCommand.
- */
-public class CreateDomainModelCommand extends ModelCreationCommandBase {
-
- public static final String COMMAND_ID = "Domain";
-
- /**
- * @see org.eclipse.papyrus.infra.core.extension.commands.ModelCreationCommandBase#createRootElement()
- *
- * @return
- */
-
- @Override
- protected EObject createRootElement() {
- return UMLFactory.eINSTANCE.createModel();
- }
-
- /**
- * @see org.eclipse.papyrus.infra.core.extension.commands.ModelCreationCommandBase#initializeModel(org.eclipse.emf.ecore.EObject)
- *
- * @param owner
- */
-
- @Override
- protected void initializeModel(EObject owner) {
- super.initializeModel(owner);
- ((org.eclipse.uml2.uml.Package) owner).setName(getModelName());
- }
-
- /**
- * Gets the model name.
- *
- * @return the model name
- */
- protected String getModelName() {
- return "DomainModel";
- }
-}
diff --git a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src/org/eclipse/papyrus/uml/diagram/domain/policies/CustomDragDropEditPolicy.java b/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src/org/eclipse/papyrus/uml/diagram/domain/policies/CustomDragDropEditPolicy.java deleted file mode 100644 index 92f24fe887d..00000000000 --- a/extraplugins/domainmodel/org.eclipse.papyrus.uml.diagram.domain/src/org/eclipse/papyrus/uml/diagram/domain/policies/CustomDragDropEditPolicy.java +++ /dev/null @@ -1,26 +0,0 @@ -/*****************************************************************************
- * Copyright (c) 2010 CEA LIST.
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.diagram.domain.policies;
-
-import org.eclipse.papyrus.uml.diagram.domain.edit.policy.DomainDiagramDragDropEditPolicy;
-
-/**
- * <pre>
- * Customization of the DND edit policy for the Package Diagram.
- *
- * Never use specific drop implemented in ClassDiagram, which are
- * related to elements that are not used currently in PackageDiagram.
- * </pre>
- */
-public class CustomDragDropEditPolicy extends DomainDiagramDragDropEditPolicy {
-
-
-
-}
|