Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuentin Le Menez2018-03-11 12:28:18 -0400
committerQuentin Le Menez2018-03-11 18:39:35 -0400
commit6a85d3a05d3bd942dba8e71edf82e97dce813b91 (patch)
treec58695b63c497d3af16b69f1634d3eb2de0deb49 /plugins/developer
parentba98ab1ef4202d0489df0ae2dd2aee8fe6f378d4 (diff)
downloadorg.eclipse.papyrus-6a85d3a05d3bd942dba8e71edf82e97dce813b91.tar.gz
org.eclipse.papyrus-6a85d3a05d3bd942dba8e71edf82e97dce813b91.tar.xz
org.eclipse.papyrus-6a85d3a05d3bd942dba8e71edf82e97dce813b91.zip
[Releng] [Photon] Delete old Dev framework and add a new Toolsmiths one
- Delete the old Dev releng profile and replace it with a Toolsmith one - Add new features: Junit, Releng, Diagramgen and Debug to be released - Move the junit framework at the root of the junit test folder - Remove Toolsmiths from the main build as it will have its own - Repopulate the SDK feature and distribute the excess features in theit own root parent - Add a new views feature - Moved the assistants to the toolsmiths folder and put them in the toolsmiths build Change-Id: I1c0331b25607baaf1cfcc635d9c7b0d9c6d73e63 Signed-off-by: Quentin Le Menez <quentin.lemenez@cea.fr>
Diffstat (limited to 'plugins/developer')
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/.project53
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/META-INF/MANIFEST.MF19
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/about.html26
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/build.properties9
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/plugin.properties12
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/plugin.xml30
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/resource/PapyrusLogo16x16.gifbin963 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/Activator.java66
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusCodegenEmitters.java116
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusExecuteTemplatesOperation.java37
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusGenerator.java93
-rw-r--r--plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/actions/PapyrusExecuteTemplateAction.java33
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.classpath8
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.project81
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.resources.prefs3
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.core.prefs292
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.m2e.core.prefs4
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.core.Xtend.prefs6
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.shared.ui.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/META-INF/MANIFEST.MF25
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/about.html26
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/build.properties11
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/plugin.properties12
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/pom.xml61
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend-gen/.gitignore2
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ChildNodeLabelEditPart.xtend43
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/CompartmentEditPart.xtend87
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/DiagramEditPart.xtend28
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ExternalNodeLabelEditPart.xtend83
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkEditPart.xtend30
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend73
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeEditPart.xtend112
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeLabelEditPart.xtend78
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/actions/LoadResourceAction.xtend21
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChildNodeLabelEditPart.xtend41
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChoiceUtils_qvto.xtend33
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/CompartmentEditPart.xtend69
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/DiagramEditPart.xtend102
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ExternalNodeLabelEditPart.xtend30
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkEditPart.xtend118
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkLabelEditPart.xtend47
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeEditPart.xtend489
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeLabelEditPart.xtend49
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend826
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/update/CanonicalUpdate.xtend163
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/parsers/ParserProvider.xtend156
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/preferences/StandardPage.xtend58
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/Facility.xtend32
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/MetaModel.xtend16
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.def/xtend/aspects/parsers/PredefinedParser.xtend65
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/CodeStyle.xtend12
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/Common.xtend44
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/QualifiedClassNameProvider.xtend30
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateLinkUtils.xtend82
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateNodeCommand.xtend227
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/ReorientLinkUtils.xtend65
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/BaseEditHelper.xtend25
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/EditHelper.xtend37
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/Common.xtend58
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/EditPartFactory.xtend75
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/BaseItemSemanticEditPolicy.xtend387
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/CompartmentItemSemanticEditPolicy.xtend130
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/DiagramItemSemanticEditPolicy.xtend20
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/LinkItemSemanticEditPolicy.xtend54
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/NodeItemSemanticEditPolicy.xtend253
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/OpenDiagram.xtend77
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextNonResizableEditPolicy.xtend39
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextSelectionEditPolicy.xtend56
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/Utils_qvto.xtend42
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/childContainerCreateCommand.xtend71
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/linkCommands.xtend194
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/PreferenceInitializer.xtend27
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/extensions.xtend70
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/DiagramUpdater.xtend361
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/Extensions.xtend24
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/LinkDescriptor.xtend41
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/NodeDescriptor.xtend34
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend54
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ActionBarContributor.xtend47
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/CreationWizard.xtend174
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DeleteElementAction.xtend30
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramContentInitializer.xtend30
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorContextMenuProvider.xtend83
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorUtil.xtend106
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DocumentProvider.xtend336
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/Editor.xtend550
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/InitDiagramFileAction.xtend81
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ModelElementSelectionPage.xtend21
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/NewDiagramFileWizard.xtend212
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetInfo.xtend60
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetModificationListener.xtend66
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ValidateAction.xtend213
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/VisualIDRegistry.xtend339
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/extensions.xtend105
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/palette/PaletteConfiguration.xtend113
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/palette/PaletteFactory.xtend119
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/palette/Utils_qvto.xtend205
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/expressions/AbstractExpression.xtend64
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/AbstractNavigatorItem.xtend55
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/DomainNavigatorContentProvider.xtend41
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/DomainNavigatorItem.xtend58
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/NavigatorContentProvider.xtend391
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/NavigatorGroup.xtend40
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/NavigatorItem.xtend49
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/NavigatorLabelProvider.xtend63
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/NavigatorLinkHelper.xtend42
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/navigator/NavigatorSorter.xtend42
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/plugin/ActivatorImpl.xtend163
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/plugin/manifest.xtend80
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/plugin/plugin.xtend292
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/propsheet/LabelProvider.xtend66
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/propsheet/PropertySection.xtend21
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/EditPartProvider.xtend26
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/ElementInitializers.xtend123
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/ElementInitializers_qvto.xtend36
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/ElementTypes.xtend173
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/IconProvider.xtend26
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/MarkerNavigationProvider.xtend92
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/ParserUtils_qvto.xtend35
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/ValidationDecoratorProvider.xtend85
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/ValidationProvider.xtend205
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/ViewProvider.xtend684
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/VisualTypeProvider.xtend98
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/providers/extensions.xtend225
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/utils/EditHelperUtils_qvto.xtend18
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/utils/EditPartsUtils_qvto.xtend45
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/utils/NodeConstraintUtils_qvto.xtend53
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/utils/PrefsConstant_qvto.xtend91
-rw-r--r--plugins/developer/org.eclipse.papyrus.def/xtend/utils/UtilsItemSemanticEditPolicy.xtend54
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.classpath8
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.project53
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/.settings/org.eclipse.xtend.core.Xtend.prefs30
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/META-INF/MANIFEST.MF16
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/build.properties19
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/plugin.properties25
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/plugin.xml115
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/pom.xml53
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/generator/ElementTypeToAssistantRule.xtend87
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/generator/ElementTypesToAssistantsGenerator.java49
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/generator/GMFGenToAssistantRule.xtend149
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/generator/GMFGenToAssistantsGenerator.java51
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/generator/GeneratorModule.java54
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/generator/ModelingAssistantProviderRule.xtend58
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/internal/Activator.java62
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/internal/handlers/AddPopupBarEditPolicyHandler.java97
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/internal/handlers/GenerateModelingAssistantsFromElementTypesHandler.java75
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/src/org/eclipse/papyrus/dev/assistants/codegen/internal/handlers/GenerateModelingAssistantsFromGMFGenHandler.java75
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.assistants.codegen/xtend-gen/.gitignore1
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/.classpath7
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/.project52
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.pluginexplorer/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.pluginexplorer/.settings/org.eclipse.core.runtime.prefs2
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.pluginexplorer/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.pluginexplorer/.settings/org.eclipse.pde.api.tools.prefs98
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/META-INF/MANIFEST.MF14
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/about.html28
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/build.properties9
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/icons/classf_obj.gifbin373 -> 0 bytes
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/icons/file_obj.gifbin354 -> 0 bytes
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/icons/jar_obj.gifbin587 -> 0 bytes
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/icons/packagefolder_obj.gifbin709 -> 0 bytes
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/icons/plugin_obj.gifbin328 -> 0 bytes
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/icons/sample.gifbin983 -> 0 bytes
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/plugin.properties19
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/plugin.xml19
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.pluginexplorer/pom.xml13
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/Activator.java109
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/EmbeddedFile.java168
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/PhysicalFile.java178
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/Plugin.java262
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/PluginEntry.java86
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/PluginsContentDialog.java194
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/PluginsContentLabelProvider.java36
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/PluginsContentProvider.java152
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/PluginsContentSelectionValidator.java40
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.dev.pluginexplorer/src/org/eclipse/papyrus/dev/pluginexplorer/PluginsContentView.java156
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/META-INF/MANIFEST.MF23
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/OSGI-INF/l10n/bundle.properties3
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/build.properties10
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/copyright_icon.pngbin281 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/feature_obj.gifbin585 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/html.gifbin362 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/papyrus.pngbin602 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/plugin_mf_obj.gifbin597 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/plugin_obj.gifbin328 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/version.gifbin868 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/icons/version.pngbin289 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/plugin.xml206
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/resources/about.html.file106
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/resources/epl-v10.html.file304
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/resources/license.html.file108
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/Activator.java63
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/dialog/InputDialogWithCheckBox.java96
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/dialog/TwoInputDialog.java138
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/AbstractAddFileHandler.java127
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/EnsureAPIAnalysisHandler.java130
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/SyncManifestAndPOMVersions.java273
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/features/AddFEPLFileHandler.java48
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/features/AddFeatureLicenseFileHandler.java48
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/features/SetCopyrightNoticeHandler.java97
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/plugins/AbstractManifestUpdateHandler.java140
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/plugins/AddProjectAboutFileHandler.java48
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/plugins/OpenParentPOMHandler.java193
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/plugins/OptimizeDependenciesHandler.java40
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/plugins/SingletonBundleHandler.java22
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/handlers/plugins/UpdateDependencyRangesHandler.java42
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/internal/operations/AbstractManifestUpdateOperation.java68
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/internal/operations/DependencyAnalysisContext.java705
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/internal/operations/DependencyKind.java81
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/internal/operations/OptimizeDependenciesOperation.java104
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/internal/operations/SingletonBundle.java74
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/internal/operations/UpdateDependencyRangesOperation.java81
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/internal/operations/VersionRules.java221
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.project.management/src/org/eclipse/papyrus/dev/project/management/utils/Utils.java71
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.classpath8
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.project53
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.settings/org.eclipse.m2m.qvt.oml.mmodel.urimap4
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/META-INF/MANIFEST.MF20
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/build.properties22
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/icons/Papyrus.gifbin561 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/plugin.properties15
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/plugin.xml159
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/pom.xml50
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/Activator.java82
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/generator/ElementTypeRegistryGenerator.xtend61
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/handlers/ElementTypeInfo.java72
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/handlers/GenerateElementTypesRegistry.java105
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/handlers/MigrateSpecializations.java275
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/handlers/MigrateTypesConfigurations.java355
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/providers/ElementTypesContentProvider.java85
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/providers/ElementTypesDetailsContentProvider.java170
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/providers/ElementTypesDetailsLabelProvider.java39
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/providers/ElementTypesLabelProvider.java45
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/providers/TypesEventContentProvider.java161
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/providers/TypesEventLabelProvider.java135
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/utils/EClassComparator.java25
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/utils/ElementTypeConfigurationComparator.java25
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/utils/ElementTypeRegistryUtils.java45
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/utils/GenerateElementTypesConfigurationsUtils.java112
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/utils/IElementTypeComparator.java25
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/utils/NotifierNullEditHelper.java30
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/utils/TypesEventPrinter.java138
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/view/RegistredElementTypesView.java196
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/src/org/eclipse/papyrus/dev/types/view/TypesConfigurationsListenerView.java227
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/transforms/VisualID Migration/GenerateUMLDIElementTypes.qvto750
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/transforms/VisualID Migration/GuessVisualID.qvto92
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/transforms/VisualID Migration/MigrateVisualID.qvto166
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/transforms/VisualID Migration/PrintVisualID.qvto118
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/transforms/VisualID Migration/PrintVisualIDMap.qvto125
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/transforms/VisualID Migration/VisualIDs_1.1_To_2.0.xlsxbin97784 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.types/xtend-gen/.gitignore1
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/.project28
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/.settings/org.eclipse.jdt.core.prefs7
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/.settings/org.eclipse.m2e.core.prefs4
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/META-INF/MANIFEST.MF17
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/build.properties9
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/icons/papyrus/Papyrus_16x16.gifbin561 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/plugin.properties12
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/plugin.xml33
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.ui/src/org/eclipse/papyrus/dev/ui/Activator.java80
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/META-INF/MANIFEST.MF14
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/build.properties10
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/icons/serviceeditview.pngbin1212 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/plugin.properties6
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/plugin.xml43
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/src/org/eclipse/papyrus/dev/view/services/edit/request/Activator.java67
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/src/org/eclipse/papyrus/dev/view/services/edit/request/helper/ViewEditHelperAdvice.java49
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/src/org/eclipse/papyrus/dev/view/services/edit/request/messages/Messages.java21
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/src/org/eclipse/papyrus/dev/view/services/edit/request/messages/messages.properties3
-rw-r--r--plugins/developer/org.eclipse.papyrus.dev.view.services.edit.request/src/org/eclipse/papyrus/dev/view/services/edit/request/view/RequestView.java193
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/META-INF/MANIFEST.MF17
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/build.properties9
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/icons/Papyrus.gifbin561 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/plugin.properties5
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/plugin.xml19
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/src/org/eclipse/papyrus/gmf/editpartview/Activator.java54
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/src/org/eclipse/papyrus/gmf/editpartview/view/EditPartHierarchyView.java222
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpartview/src/org/eclipse/papyrus/gmf/editpartview/view/EditPartLabelProvider.java98
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/META-INF/MANIFEST.MF14
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/build.properties9
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/icons/Papyrus.gifbin561 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/plugin.properties5
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/plugin.xml19
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/src/org/eclipse/papyrus/gmf/editpoliciesstates/Activator.java67
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/src/org/eclipse/papyrus/gmf/editpoliciesstates/view/EditPoliciesStateView.java290
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.editpoliciesstates/src/org/eclipse/papyrus/gmf/editpoliciesstates/view/EditpolicyLabelProvider.java101
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/META-INF/MANIFEST.MF16
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/build.properties10
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/icons/Papyrus.gifbin561 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/plugin.properties5
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/plugin.xml19
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/src/org/eclipse/papyrus/gmf/figureview/Activator.java54
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/src/org/eclipse/papyrus/gmf/figureview/view/FigureHierarchyView.java228
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmf.figureview/src/org/eclipse/papyrus/gmf/figureview/view/FigureLabelProvider.java121
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/.settings/org.eclipse.jdt.core.prefs292
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/META-INF/MANIFEST.MF21
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/about.html26
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/build.properties17
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/icons/GenerateMetamodelType.gifbin547 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/icons/PapyrusLogo16x16.gifbin561 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/icons/none_comp_vis.gifbin115 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/icons/palette_view.gifbin633 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/icons/updateElementType.gifbin330 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/model/gmfgneExtension.uml169
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/model/papyrusGmfgenExtension.ecore202
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/model/papyrusGmfgenExtension.genmodel111
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/plugin.properties12
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/plugin.xml309
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/AdditionalEditPartCandies.java59
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/AlternateCanvas.java125
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/AlternateGenLink.java88
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/AlternateGenTopLevelNode.java88
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/CommentedElement.java59
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/CompartmentTitleVisibilityPreference.java84
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/CompartmentVisibilityPreference.java84
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/ConstrainedByReferenceCompartmentItemSemanticEditPolicy.java52
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/CustomDiagramUpdaterSingleton.java59
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/EditPartUsingDeleteService.java87
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/EditPartUsingReorientService.java87
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/ExtendedGenView.java185
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/ExternalHook.java64
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/GenNodeConstraint.java80
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/GenVisualTypeProvider.java115
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/GenerateUsingElementTypeCreationCommand.java27
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/LabelVisibilityPreference.java161
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/MutatingCanvas.java50
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/OwnedEditpart.java59
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/PapyrusExtensionRootNode.java50
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/PapyrusgmfgenextensionFactory.java277
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/PapyrusgmfgenextensionPackage.java2740
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/PropertyRefreshHook.java93
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/SpecificDiagramUpdater.java74
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/SpecificLocator.java66
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/SpecificLocatorExternalLabel.java66
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/SpecificNodePlate.java114
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/VisualIDOverride.java108
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/AdditionalEditPartCandiesImpl.java172
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/AlternateCanvasImpl.java324
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/AlternateGenLinkImpl.java247
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/AlternateGenTopLevelNodeImpl.java247
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/CommentedElementImpl.java173
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/CompartmentTitleVisibilityPreferenceImpl.java215
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/CompartmentVisibilityPreferenceImpl.java215
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/ConstrainedByReferenceCompartmentItemSemanticEditPolicyImpl.java143
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/CustomDiagramUpdaterSingletonImpl.java172
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/EditPartUsingDeleteServiceImpl.java215
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/EditPartUsingReorientServiceImpl.java215
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/ExtendedGenViewImpl.java438
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/ExternalHookImpl.java172
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/GenNodeConstraintImpl.java209
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/GenVisualTypeProviderImpl.java172
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/GenerateUsingElementTypeCreationCommandImpl.java47
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/LabelVisibilityPreferenceImpl.java358
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/MutatingCanvasImpl.java160
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/OwnedEditpartImpl.java172
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/PapyrusExtensionRootNodeImpl.java160
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/PapyrusgmfgenextensionFactoryImpl.java380
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/PapyrusgmfgenextensionPackageImpl.java1278
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/PropertyRefreshHookImpl.java226
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/SpecificDiagramUpdaterImpl.java167
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/SpecificLocatorExternalLabelImpl.java143
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/SpecificLocatorImpl.java143
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/SpecificNodePlateImpl.java269
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/impl/VisualIDOverrideImpl.java293
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/Action.java182
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddDefaultNamedElementAction.java163
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddExternalNodeFloatingLabelDisplayBehavior.java223
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddExternalNodeStereotypeDisplayBehavior.java167
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddGenLinkStereotypeDisplayBehavior.java221
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddHyperLinkPopupBarBehavior.java70
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddNodeQualifiedNameBehavior.java69
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddNodeShowHideCompartmentBehavior.java56
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddNodeShowHideContentsBehavior.java51
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddNodeShowHideLabelsBehavior.java53
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddNodeStereotypeDisplayBehavior.java69
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddOrUpdateCommentEditParts.java577
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddSemanticElementTypeInGenericTopNode.java191
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddShapeNamedElementAction.java173
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/AddSmallAndLargeIconForPaletteAction.java215
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/DisplayReport.java147
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/EditpartGenHelper.java259
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/Messages.java51
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/SetCompartmentNeedsTitleToTrueAction.java66
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/SetVisualIDWithUnusedValue.java123
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/TestCodeSetGeneration.java204
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/UpdateElementTypeToMatchGenericType.java256
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/popupaction/messages.properties5
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/util/PapyrusgmfgenextensionAdapterFactory.java580
-rw-r--r--plugins/developer/org.eclipse.papyrus.gmfgenextension/src/org/eclipse/papyrus/papyrusgmfgenextension/util/PapyrusgmfgenextensionSwitch.java674
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/META-INF/MANIFEST.MF16
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/build.properties8
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/icons/stack.gifbin575 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/plugin.properties5
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/plugin.xml20
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/src/org/eclipse/papyrus/infra/emf/commandstack/Activator.java63
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.emf.commandstack/src/org/eclipse/papyrus/infra/emf/commandstack/view/CommandStackView.java285
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/.project47
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/META-INF/MANIFEST.MF12
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/OSGI-INF/l10n/bundle.properties3
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/build.properties9
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/icons/sourceEditor.gifbin353 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/plugin.xml21
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/pom.xml13
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/src/org/eclipse/papyrus/infra/gmfdiag/css/debug/Activator.java69
-rw-r--r--plugins/developer/org.eclipse.papyrus.infra.gmfdiag.css.debug/src/org/eclipse/papyrus/infra/gmfdiag/css/debug/views/CSSDebugView.java610
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/.classpath9
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/.project53
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/META-INF/MANIFEST.MF19
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/OSGI-INF/l10n/bundle.properties3
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/build.properties9
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/Activator.java45
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/XtendWorkflow.java38
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/components/MultiReader.java74
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/components/QvtoTransformationWorkflow.java144
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/components/RegisterUmlProfile.java123
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/components/UMLWriter.java274
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/messages/Messages.java55
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/src/org/eclipse/papyrus/mwe2/utils/messages/messages.properties12
-rw-r--r--plugins/developer/org.eclipse.papyrus.mwe2.utils/xtend-gen/.gitignore2
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/.classpath6
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/.project35
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/META-INF/MANIFEST.MF8
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/OSGI-INF/l10n/bundle.properties14
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/build.properties7
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/pom.xml15
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.releng.dev.release/release.digestbin2243 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.dev.release/release.properties5
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.releng.dev.release/release.xml74
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/.classpath6
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/.project35
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/META-INF/MANIFEST.MF8
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/OSGI-INF/l10n/bundle.properties14
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/build.properties7
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/pom.xml15
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.releng.main.release/release.digestbin283 -> 0 bytes
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.main.release/release.properties5
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.releng.main.release/release.xml825
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/.project57
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/.settings/org.eclipse.pde.api.tools.prefs98
-rwxr-xr-xplugins/developer/org.eclipse.papyrus.releng.tools/META-INF/MANIFEST.MF19
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/OSGI-INF/l10n/bundle.properties14
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/README.TXT18
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/build.properties19
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/plugin.xml110
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/pom.xml14
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/Activator.java47
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/Messages.java31
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/handler/AddSetupRepositoryUpdateAnnotationHandler.java422
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/handler/UpdateDependenciesHandler.java49
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/messages.properties18
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/DependencyUpdater.java437
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/GenerateTargetsHandler.java337
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/MapUpdater.java66
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/OomphSetupUpdater.java259
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/PomPropertiesUpdater.java48
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/PomUpdater.java48
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/TPDUpdater.java142
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/UpdateDependencies.java243
-rw-r--r--plugins/developer/org.eclipse.papyrus.releng.tools/src/org/eclipse/papyrus/releng/tools/internal/popup/actions/XMLDependencyUpdater.java133
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.classpath7
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.gitignore1
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.project28
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.settings/org.eclipse.core.resources.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.settings/org.eclipse.jdt.core.prefs291
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.settings/org.eclipse.jdt.ui.prefs68
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/.settings/org.eclipse.pde.api.tools.prefs98
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/META-INF/MANIFEST.MF20
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/OSGI-INF/l10n/bundle.properties3
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/about.html28
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/build.properties8
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/pom.xml15
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/src/org/eclipse/papyrus/uml/m2m/qvto/tests/tools/Activator.java81
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/src/org/eclipse/papyrus/uml/m2m/qvto/tests/tools/tests/AbstractImportModelTests.java833
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/src/org/eclipse/papyrus/uml/m2m/qvto/tests/tools/tests/EMFCompareUtils.java125
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/src/org/eclipse/papyrus/uml/m2m/qvto/tests/tools/tests/PapyrusProximityEObjectMatcher.java493
-rw-r--r--plugins/developer/org.eclipse.papyrus.uml.m2m.qvto.tests.tools/src/org/eclipse/papyrus/uml/m2m/qvto/tests/tools/tests/UMLIgnoringIdentifiedEqualityHelper.java161
-rw-r--r--plugins/developer/pom.xml37
589 files changed, 0 insertions, 58704 deletions
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/.classpath b/plugins/developer/org.eclipse.papyrus.codegen/.classpath
deleted file mode 100644
index eca7bdba8f0..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/.classpath
+++ /dev/null
@@ -1,7 +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/JavaSE-1.8"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/.project b/plugins/developer/org.eclipse.papyrus.codegen/.project
deleted file mode 100644
index d627a772b68..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/.project
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.papyrus.codegen</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.openarchitectureware.base.oawBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.oomph.version.VersionBuilder</name>
- <arguments>
- <dictionary>
- <key>check.maven.pom</key>
- <value>true</value>
- </dictionary>
- <dictionary>
- <key>ignore.lower.bound.dependency.ranges</key>
- <value>true</value>
- </dictionary>
- <dictionary>
- <key>release.path</key>
- <value>/org.eclipse.papyrus.releng.dev.release/release.xml</value>
- </dictionary>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.openarchitectureware.base.oawNature</nature>
- <nature>org.eclipse.oomph.version.VersionNature</nature>
- <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
- </natures>
-</projectDescription>
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.resources.prefs b/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index 896a9a53a53..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8 \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.runtime.prefs b/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644
index 5a0ad22d2a7..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.core.runtime.prefs
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.core.prefs b/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index b3aa6d60f94..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,291 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
-org.eclipse.jdt.core.compiler.compliance=1.8
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.8
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_lambda_body=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=260
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_type_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_lambda_arrow=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_lambda_arrow=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=false
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=260
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=5
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=tab
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.ui.prefs b/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 954281dbc31..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,68 +0,0 @@
-cleanup.add_default_serial_version_id=true
-cleanup.add_generated_serial_version_id=false
-cleanup.add_missing_annotations=true
-cleanup.add_missing_deprecated_annotations=true
-cleanup.add_missing_methods=false
-cleanup.add_missing_nls_tags=false
-cleanup.add_missing_override_annotations=true
-cleanup.add_missing_override_annotations_interface_methods=true
-cleanup.add_serial_version_id=false
-cleanup.always_use_blocks=true
-cleanup.always_use_parentheses_in_expressions=false
-cleanup.always_use_this_for_non_static_field_access=false
-cleanup.always_use_this_for_non_static_method_access=false
-cleanup.convert_functional_interfaces=false
-cleanup.convert_to_enhanced_for_loop=false
-cleanup.correct_indentation=false
-cleanup.format_source_code=false
-cleanup.format_source_code_changes_only=false
-cleanup.insert_inferred_type_arguments=false
-cleanup.make_local_variable_final=true
-cleanup.make_parameters_final=false
-cleanup.make_private_fields_final=true
-cleanup.make_type_abstract_if_missing_method=false
-cleanup.make_variable_declarations_final=false
-cleanup.never_use_blocks=false
-cleanup.never_use_parentheses_in_expressions=true
-cleanup.organize_imports=false
-cleanup.qualify_static_field_accesses_with_declaring_class=false
-cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-cleanup.qualify_static_member_accesses_with_declaring_class=true
-cleanup.qualify_static_method_accesses_with_declaring_class=false
-cleanup.remove_private_constructors=true
-cleanup.remove_redundant_type_arguments=true
-cleanup.remove_trailing_whitespaces=true
-cleanup.remove_trailing_whitespaces_all=true
-cleanup.remove_trailing_whitespaces_ignore_empty=false
-cleanup.remove_unnecessary_casts=true
-cleanup.remove_unnecessary_nls_tags=true
-cleanup.remove_unused_imports=true
-cleanup.remove_unused_local_variables=false
-cleanup.remove_unused_private_fields=true
-cleanup.remove_unused_private_members=false
-cleanup.remove_unused_private_methods=true
-cleanup.remove_unused_private_types=true
-cleanup.sort_members=false
-cleanup.sort_members_all=false
-cleanup.use_anonymous_class_creation=false
-cleanup.use_blocks=true
-cleanup.use_blocks_only_for_return_and_throw=false
-cleanup.use_lambda=true
-cleanup.use_parentheses_in_expressions=false
-cleanup.use_this_for_non_static_field_access=false
-cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-cleanup.use_this_for_non_static_method_access=false
-cleanup.use_this_for_non_static_method_access_only_if_necessary=true
-cleanup.use_type_arguments=false
-cleanup_profile=_Papyrus
-cleanup_settings_version=2
-eclipse.preferences.version=1
-formatter_profile=_Papyrus
-formatter_settings_version=12
-org.eclipse.jdt.ui.ignorelowercasenames=true
-org.eclipse.jdt.ui.importorder=java;javax;org;com;
-org.eclipse.jdt.ui.javadoc=true
-org.eclipse.jdt.ui.ondemandthreshold=99
-org.eclipse.jdt.ui.staticondemandthreshold=99
-org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><templates><template autoinsert\="true" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment">/**\n * @return the ${bare_field_name}\n */</template><template autoinsert\="true" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment">/**\n * @param ${param} the ${bare_field_name} to set\n */</template><template autoinsert\="false" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment">/**\n * Constructor.\n *\n * ${tags}\n */</template><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*****************************************************************************\n * Copyright (c) ${year} CEA LIST and others.\n * \n * All rights reserved. This program and the accompanying materials\n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http\://www.eclipse.org/legal/epl-v10.html\n *\n * Contributors\:\n * CEA LIST - Initial API and implementation\n * \n *****************************************************************************/\n</template><template autoinsert\="true" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\n * @author ${user}\n *\n * ${tags}\n */</template><template autoinsert\="true" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment">/**\n * \n */</template><template autoinsert\="true" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment">/**\n * ${tags}\n */</template><template autoinsert\="false" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment">/**\n * ${see_to_overridden}\n *\n * ${tags}\n */</template><template autoinsert\="false" context\="delegatecomment_context" deleted\="false" description\="Comment for delegate methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.delegatecomment" name\="delegatecomment">/**\n * ${see_to_target}\n *\n * ${tags}\n */</template><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\n${package_declaration}\n\n${typecomment}\n${type_declaration}</template><template autoinsert\="true" context\="classbody_context" deleted\="false" description\="Code in new class type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.classbody" name\="classbody">\n</template><template autoinsert\="true" context\="interfacebody_context" deleted\="false" description\="Code in new interface type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.interfacebody" name\="interfacebody">\n</template><template autoinsert\="true" context\="enumbody_context" deleted\="false" description\="Code in new enum type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.enumbody" name\="enumbody">\n</template><template autoinsert\="true" context\="annotationbody_context" deleted\="false" description\="Code in new annotation type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.annotationbody" name\="annotationbody">\n</template><template autoinsert\="true" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">// ${todo} Auto-generated catch block\n${exception_var}.printStackTrace();</template><template autoinsert\="true" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">// ${todo} Auto-generated method stub\n${body_statement}</template><template autoinsert\="true" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}\n// ${todo} Auto-generated constructor stub</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates>
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.pde.api.tools.prefs b/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644
index 23fb95e120f..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/.settings/org.eclipse.pde.api.tools.prefs
+++ /dev/null
@@ -1,98 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Ignore
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_ANNOTATION=Ignore
-INVALID_JAVADOC_TAG=Ignore
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Ignore
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=Enabled
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Warning
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/META-INF/MANIFEST.MF b/plugins/developer/org.eclipse.papyrus.codegen/META-INF/MANIFEST.MF
deleted file mode 100644
index 0e270123c73..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,19 +0,0 @@
-Manifest-Version: 1.0
-Export-Package: org.eclipse.papyrus.codegen;x-internal:=true,
- org.eclipse.papyrus.codegen.actions;x-internal:=true
-Require-Bundle: org.eclipse.ui;bundle-version="[3.107.0,4.0.0)",
- org.eclipse.gmf.codegen.ui;bundle-version="[1.3.0,2.0.0)",
- org.eclipse.gmf.codegen.xtend;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.gmf.codegen.xtend.ui;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.papyrus.infra.core.log;bundle-version="[1.2.0,2.0.0)",
- org.eclipse.papyrus.def;bundle-version="[1.2.0,2.0.0)",
- org.eclipse.papyrus.gmfgenextension;bundle-version="[2.0.0,3.0.0)"
-Bundle-Vendor: %providerName
-Bundle-ActivationPolicy: lazy
-Bundle-Version: 1.2.0.qualifier
-Bundle-Name: %pluginName
-Bundle-Localization: plugin
-Bundle-Activator: org.eclipse.papyrus.codegen.Activator
-Bundle-ManifestVersion: 2
-Bundle-SymbolicName: org.eclipse.papyrus.codegen;singleton:=true
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/about.html b/plugins/developer/org.eclipse.papyrus.codegen/about.html
deleted file mode 100644
index 23506a4bae1..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/about.html
+++ /dev/null
@@ -1,26 +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, 2006</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> \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/build.properties b/plugins/developer/org.eclipse.papyrus.codegen/build.properties
deleted file mode 100644
index 687dcfda295..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/build.properties
+++ /dev/null
@@ -1,9 +0,0 @@
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- about.html,\
- plugin.properties,\
- resource/
-src.includes = about.html
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/plugin.properties b/plugins/developer/org.eclipse.papyrus.codegen/plugin.properties
deleted file mode 100644
index c951b54bee9..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/plugin.properties
+++ /dev/null
@@ -1,12 +0,0 @@
-#################################################################################
-# Copyright (c) 2008 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:
-# Cedric Dumoulin Cedric.dumoulin@lifl.fr - Initial API and implementation
-##################################################################################
-pluginName=Papyrus Code Generator for GmfGen models
-providerName=Eclipse Modeling Project
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/plugin.xml b/plugins/developer/org.eclipse.papyrus.codegen/plugin.xml
deleted file mode 100644
index 198fd989808..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/plugin.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
- <extension
- point="org.eclipse.ui.popupMenus">
- <objectContribution
- adaptable="true"
- id="org.eclipse.papyrus.codegen.executeTemplate"
- nameFilter="*.gmfgen"
- objectClass="org.eclipse.core.resources.IFile">
- <action
- class="org.eclipse.papyrus.codegen.actions.PapyrusExecuteTemplateAction"
- enablesFor="1"
- icon="resource/PapyrusLogo16x16.gif"
- id="org.eclipse.papyrus.codegen.executeTemplateAction"
- label="Generate Papyrus diagram"
- menubarPath="additions">
- </action>
- </objectContribution>
- </extension>
- <extension point="org.eclipse.ui.navigator.viewer">
- <viewerContentBinding viewerId="org.eclipse.papyrus.infra.core.papyrusEditor">
- <includes>
- <contentExtension pattern="org.eclipse.papyrus.infra.core.modelOutline"/>
- <!--contentExtension pattern="org.eclipse.papyrus.infra.core.viewOutline"/-->
- </includes>
- </viewerContentBinding>
- </extension>
-
-</plugin>
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/pom.xml b/plugins/developer/org.eclipse.papyrus.codegen/pom.xml
deleted file mode 100644
index 5630c9df6f6..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/pom.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <artifactId>org.eclipse.papyrus.developer</artifactId>
- <groupId>org.eclipse.papyrus</groupId>
- <version>0.0.1-SNAPSHOT</version>
- </parent>
- <artifactId>org.eclipse.papyrus.codegen</artifactId>
- <groupId>org.eclipse.papyrus</groupId>
- <version>1.2.0-SNAPSHOT</version>
- <packaging>eclipse-plugin</packaging>
-</project>
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/resource/PapyrusLogo16x16.gif b/plugins/developer/org.eclipse.papyrus.codegen/resource/PapyrusLogo16x16.gif
deleted file mode 100644
index a32f4b1b572..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/resource/PapyrusLogo16x16.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/Activator.java b/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/Activator.java
deleted file mode 100644
index b517b364d6d..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/Activator.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/****************************************************************************
- * Copyright (c) 2008 Atos Origin.
- *
- * 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.codegen;
-
-import org.eclipse.papyrus.infra.core.log.LogHelper;
-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.codegen";
-
- // The shared instance
- private static Activator plugin;
-
- public static LogHelper log;
-
- /**
- * The 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;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
- */
- @Override
- public void stop(BundleContext context) throws Exception {
- plugin = null;
- super.stop(context);
- }
-
- /**
- * Returns the shared instance
- *
- * @return the shared instance
- */
- public static Activator getDefault() {
- return plugin;
- }
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusCodegenEmitters.java b/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusCodegenEmitters.java
deleted file mode 100644
index df97b3f0e2b..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusCodegenEmitters.java
+++ /dev/null
@@ -1,116 +0,0 @@
-/****************************************************************************
- * Copyright (c) 2008, 2017 Atos Origin, CEA, ALL4TEC.
- *
- * 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:
- * Thibault Landre (Atos Origin) - Initial API and implementation
- * Mickaël ADAM (ALL4TEC) mickael.adam@all4tec.net - Bug 510587: the palette must not be generated by using GMF gen
- *
- *****************************************************************************/
-package org.eclipse.papyrus.codegen;
-
-import org.eclipse.gmf.codegen.xtend.ui.handlers.CodegenEmittersWithXtend2;
-import org.eclipse.gmf.common.UnexpectedBehaviourException;
-import org.eclipse.gmf.internal.common.codegen.JavaClassEmitter;
-import org.eclipse.gmf.internal.common.codegen.TextEmitter;
-
-@SuppressWarnings("restriction")
-public class PapyrusCodegenEmitters extends CodegenEmittersWithXtend2 {
-
- public PapyrusCodegenEmitters(boolean useBaseTemplatesOnly, String templateDirectory, boolean includeDynamicModelTemplates) {
- super(useBaseTemplatesOnly, templateDirectory, includeDynamicModelTemplates);
- }
-
- @Override
- public JavaClassEmitter getDiagramCanonicalEditPolicyEmitter() {
- return null;
- }
-
- @Override
- public JavaClassEmitter getUpdateCommandEmitter() {
- return null;
- }
-
- @Override
- public JavaClassEmitter getModelingAssistantProviderEmitter() throws UnexpectedBehaviourException {
- return null;
- }
-
- @Override
- public JavaClassEmitter getChildContainerCanonicalEditPolicyEmitter() {
- return null;
- }
-
-
- @Override
- public JavaClassEmitter getNodeEditPartModelingAssistantProviderEmitter() {
- return null;
- }
-
- @Override
- public JavaClassEmitter getDiagramItemSemanticEditPolicyEmitter() {
- return null;
- }
-
- @Override
- public JavaClassEmitter getDeleteElementActionEmitter() {
- return null;
- }
-
- @Override
- public JavaClassEmitter getCreateNodeCommandEmitter() throws UnexpectedBehaviourException {
- return null;
- }
-
- @Override
- public JavaClassEmitter getReorientLinkCommandEmitter() throws UnexpectedBehaviourException {
- return null;
- }
-
- @Override
- public JavaClassEmitter getReorientRefLinkCommandEmitter() throws UnexpectedBehaviourException {
- return null;
- }
-
- @Override
- public JavaClassEmitter getCreateLinkCommandEmitter() throws UnexpectedBehaviourException {
- return null;
- }
-
- @Override
- public JavaClassEmitter getCompartmentItemSemanticEditPolicyEmitter() {
- return null;
- }
-
- @Override
- public JavaClassEmitter getNodeItemSemanticEditPolicyEmitter() {
- return null;
- }
-
- @Override
- public JavaClassEmitter getLinkItemSemanticEditPolicyEmitter() {
- return null;
- }
-
- /**
- * {@inheritDoc}
- * Overridden to disable code generation of old palette framework.
- *
- * @see org.eclipse.gmf.codegen.util.CodegenEmitters#getPaletteEmitter()
- */
- @Override
- public JavaClassEmitter getPaletteEmitter() throws UnexpectedBehaviourException {
- return null;
- }
-
- /**
- * Get the {@link TextEmitter} to generate palette configuration model for papyrus diagrams.
- */
- public TextEmitter getPaletteConfigurationEmitter() {
- return createJavaClassEmitter("aspects::xpt::editor::palette::PaletteConfiguration", "PaletteConfiguration"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-}
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusExecuteTemplatesOperation.java b/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusExecuteTemplatesOperation.java
deleted file mode 100644
index 75ea973e061..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusExecuteTemplatesOperation.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/****************************************************************************
- * Copyright (c) 2008, 2017 Atos Origin, CEA, ALL4TEC and others.
- *
- * 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:
- * Thibault Landre (Atos Origin) - Initial API and implementation
- * Mickaël ADAM (ALL4TEC) mickael.adam@all4tec.net - Bug 510587: the palette must not be generated by using GMF gen
- *
- *****************************************************************************/
-package org.eclipse.papyrus.codegen;
-
-import org.eclipse.gmf.codegen.gmfgen.GenEditorGenerator;
-import org.eclipse.gmf.codegen.util.Generator;
-import org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTemplatesOperation;
-
-/**
- * The Papyrus execute templates operation
- *
- * @see org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTemplatesOperation
- * @author tlandre
- */
-public class PapyrusExecuteTemplatesOperation extends ExecuteTemplatesOperation {
-
- /**
- * {@inheritDoc}
- */
- @Override
- protected Generator createGenerator() {
- GenEditorGenerator genModel = getGenModel();
- return new PapyrusGenerator(genModel, new PapyrusCodegenEmitters(!genModel.isDynamicTemplates(), genModel.getTemplateDirectory(), genModel.getModelAccess() != null));
- }
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusGenerator.java b/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusGenerator.java
deleted file mode 100644
index 5cee3e7ba91..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/PapyrusGenerator.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 CEA LIST,ALL4TEC and others.
- *
- * 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:
- * Mickaël ADAM (ALL4TEC) mickael.adam@all4tec.net - Initial API and implementation
- *****************************************************************************/
-
-package org.eclipse.papyrus.codegen;
-
-import java.io.File;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.emf.common.util.URI;
-import org.eclipse.gmf.codegen.gmfgen.GenEditorGenerator;
-import org.eclipse.gmf.codegen.xtend.ui.handlers.GeneratorWithXtend2;
-import org.eclipse.gmf.common.UnexpectedBehaviourException;
-
-/**
- * Papyrus gmf generator.
- */
-public class PapyrusGenerator extends GeneratorWithXtend2 {
-
- /**
- * The Papyrus codegen Emitters.
- */
- private final PapyrusCodegenEmitters emitters;
-
- /**
- * The editor gen model.
- */
- private GenEditorGenerator editorGen;
-
- /**
- * Constructor.
- */
- public PapyrusGenerator(final GenEditorGenerator genModel, final PapyrusCodegenEmitters codegenEmitters) {
- super(genModel, codegenEmitters);
- editorGen = genModel;
- emitters = codegenEmitters;
- }
-
- /**
- * @see org.eclipse.gmf.codegen.xtend.ui.handlers.GeneratorWithXtend2#customRun()
- *
- * @throws InterruptedException
- * @throws UnexpectedBehaviourException
- */
- @Override
- protected void customRun() throws InterruptedException, UnexpectedBehaviourException {
- super.customRun();
- // generatePaletteConfiguration(); // commented to disable paletteConfiguration model generation
- }
-
- /**
- * Generate palette configuration model.
- *
- * @throws UnexpectedBehaviourException
- * @throws InterruptedException
- */
- @SuppressWarnings("restriction")
- protected void generatePaletteConfiguration() throws UnexpectedBehaviourException, InterruptedException {
- if (null == editorGen.getDiagram().getPalette()) {
- return;
- }
- doGenerateFile(emitters.getPaletteConfigurationEmitter(), new Path(getRelativePath() + File.separator + editorGen.getModelID() + ".paletteconfiguration"), editorGen); //$NON-NLS-1$
- }
-
- /**
- * @return The relative path of the model's resource.
- */
- protected String getRelativePath() {
- String path = null;
-
- URI resourceURI = editorGen.eResource().getURI();
- if (resourceURI.isPlatformResource()) {
- String platformString = resourceURI.toPlatformString(true);
- IPath workspacePath = new Path(platformString);
- workspacePath = workspacePath.removeFirstSegments(1);
- workspacePath = workspacePath.removeLastSegments(1);
- path = workspacePath.toString();
- } else {
- path = "model";//$NON-NLS-1$
- }
- return path;
- }
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/actions/PapyrusExecuteTemplateAction.java b/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/actions/PapyrusExecuteTemplateAction.java
deleted file mode 100644
index 04a9b88288d..00000000000
--- a/plugins/developer/org.eclipse.papyrus.codegen/src/org/eclipse/papyrus/codegen/actions/PapyrusExecuteTemplateAction.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/****************************************************************************
- * Copyright (c) 2008 Atos Origin.
- *
- * 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:
- * Thibault Landre (Atos Origin) - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.codegen.actions;
-
-import org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTemplatesAction;
-import org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTemplatesOperation;
-import org.eclipse.papyrus.codegen.PapyrusExecuteTemplatesOperation;
-
-/**
- * Define the Papyrus Generate Action
- *
- * @author tlandre
- */
-public class PapyrusExecuteTemplateAction extends ExecuteTemplatesAction {
-
- /**
- * {@inheritDoc}
- */
- @Override
- protected ExecuteTemplatesOperation createOperation() {
- return new PapyrusExecuteTemplatesOperation();
- }
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/.classpath b/plugins/developer/org.eclipse.papyrus.def/.classpath
deleted file mode 100644
index 2b33b90779b..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.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/JavaSE-1.8"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="src" path="xtend"/>
- <classpathentry kind="src" path="xtend-gen"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/plugins/developer/org.eclipse.papyrus.def/.project b/plugins/developer/org.eclipse.papyrus.def/.project
deleted file mode 100644
index 2d16d0466af..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.project
+++ /dev/null
@@ -1,81 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.papyrus.def</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.xtext.ui.shared.xtextBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.openarchitectureware.base.oawBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.gmf.xpand.oawBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.gmf.xpand.xpandBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.xtend.shared.ui.xtendBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.oomph.version.VersionBuilder</name>
- <arguments>
- <dictionary>
- <key>check.maven.pom</key>
- <value>true</value>
- </dictionary>
- <dictionary>
- <key>ignore.lower.bound.dependency.ranges</key>
- <value>true</value>
- </dictionary>
- <dictionary>
- <key>release.path</key>
- <value>/org.eclipse.papyrus.releng.dev.release/release.xml</value>
- </dictionary>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.m2e.core.maven2Builder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.m2e.core.maven2Nature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.openarchitectureware.base.oawNature</nature>
- <nature>org.eclipse.xtend.shared.ui.xtendXPandNature</nature>
- <nature>org.eclipse.xtext.ui.shared.xtextNature</nature>
- <nature>org.eclipse.oomph.version.VersionNature</nature>
- <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
- </natures>
-</projectDescription>
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.resources.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index e10e3165bba..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=ISO-8859-1
-encoding/xtend=ISO-8859-1
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.runtime.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644
index 5a0ad22d2a7..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.core.runtime.prefs
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.core.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 41b887bd50e..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,292 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
-org.eclipse.jdt.core.compiler.compliance=1.8
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.8
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_lambda_body=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=260
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_type_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_lambda_arrow=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_lambda_arrow=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=false
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=260
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=5
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=tab
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
-org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.ui.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 954281dbc31..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,68 +0,0 @@
-cleanup.add_default_serial_version_id=true
-cleanup.add_generated_serial_version_id=false
-cleanup.add_missing_annotations=true
-cleanup.add_missing_deprecated_annotations=true
-cleanup.add_missing_methods=false
-cleanup.add_missing_nls_tags=false
-cleanup.add_missing_override_annotations=true
-cleanup.add_missing_override_annotations_interface_methods=true
-cleanup.add_serial_version_id=false
-cleanup.always_use_blocks=true
-cleanup.always_use_parentheses_in_expressions=false
-cleanup.always_use_this_for_non_static_field_access=false
-cleanup.always_use_this_for_non_static_method_access=false
-cleanup.convert_functional_interfaces=false
-cleanup.convert_to_enhanced_for_loop=false
-cleanup.correct_indentation=false
-cleanup.format_source_code=false
-cleanup.format_source_code_changes_only=false
-cleanup.insert_inferred_type_arguments=false
-cleanup.make_local_variable_final=true
-cleanup.make_parameters_final=false
-cleanup.make_private_fields_final=true
-cleanup.make_type_abstract_if_missing_method=false
-cleanup.make_variable_declarations_final=false
-cleanup.never_use_blocks=false
-cleanup.never_use_parentheses_in_expressions=true
-cleanup.organize_imports=false
-cleanup.qualify_static_field_accesses_with_declaring_class=false
-cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-cleanup.qualify_static_member_accesses_with_declaring_class=true
-cleanup.qualify_static_method_accesses_with_declaring_class=false
-cleanup.remove_private_constructors=true
-cleanup.remove_redundant_type_arguments=true
-cleanup.remove_trailing_whitespaces=true
-cleanup.remove_trailing_whitespaces_all=true
-cleanup.remove_trailing_whitespaces_ignore_empty=false
-cleanup.remove_unnecessary_casts=true
-cleanup.remove_unnecessary_nls_tags=true
-cleanup.remove_unused_imports=true
-cleanup.remove_unused_local_variables=false
-cleanup.remove_unused_private_fields=true
-cleanup.remove_unused_private_members=false
-cleanup.remove_unused_private_methods=true
-cleanup.remove_unused_private_types=true
-cleanup.sort_members=false
-cleanup.sort_members_all=false
-cleanup.use_anonymous_class_creation=false
-cleanup.use_blocks=true
-cleanup.use_blocks_only_for_return_and_throw=false
-cleanup.use_lambda=true
-cleanup.use_parentheses_in_expressions=false
-cleanup.use_this_for_non_static_field_access=false
-cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-cleanup.use_this_for_non_static_method_access=false
-cleanup.use_this_for_non_static_method_access_only_if_necessary=true
-cleanup.use_type_arguments=false
-cleanup_profile=_Papyrus
-cleanup_settings_version=2
-eclipse.preferences.version=1
-formatter_profile=_Papyrus
-formatter_settings_version=12
-org.eclipse.jdt.ui.ignorelowercasenames=true
-org.eclipse.jdt.ui.importorder=java;javax;org;com;
-org.eclipse.jdt.ui.javadoc=true
-org.eclipse.jdt.ui.ondemandthreshold=99
-org.eclipse.jdt.ui.staticondemandthreshold=99
-org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><templates><template autoinsert\="true" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment">/**\n * @return the ${bare_field_name}\n */</template><template autoinsert\="true" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment">/**\n * @param ${param} the ${bare_field_name} to set\n */</template><template autoinsert\="false" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment">/**\n * Constructor.\n *\n * ${tags}\n */</template><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*****************************************************************************\n * Copyright (c) ${year} CEA LIST and others.\n * \n * All rights reserved. This program and the accompanying materials\n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http\://www.eclipse.org/legal/epl-v10.html\n *\n * Contributors\:\n * CEA LIST - Initial API and implementation\n * \n *****************************************************************************/\n</template><template autoinsert\="true" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\n * @author ${user}\n *\n * ${tags}\n */</template><template autoinsert\="true" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment">/**\n * \n */</template><template autoinsert\="true" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment">/**\n * ${tags}\n */</template><template autoinsert\="false" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment">/**\n * ${see_to_overridden}\n *\n * ${tags}\n */</template><template autoinsert\="false" context\="delegatecomment_context" deleted\="false" description\="Comment for delegate methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.delegatecomment" name\="delegatecomment">/**\n * ${see_to_target}\n *\n * ${tags}\n */</template><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\n${package_declaration}\n\n${typecomment}\n${type_declaration}</template><template autoinsert\="true" context\="classbody_context" deleted\="false" description\="Code in new class type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.classbody" name\="classbody">\n</template><template autoinsert\="true" context\="interfacebody_context" deleted\="false" description\="Code in new interface type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.interfacebody" name\="interfacebody">\n</template><template autoinsert\="true" context\="enumbody_context" deleted\="false" description\="Code in new enum type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.enumbody" name\="enumbody">\n</template><template autoinsert\="true" context\="annotationbody_context" deleted\="false" description\="Code in new annotation type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.annotationbody" name\="annotationbody">\n</template><template autoinsert\="true" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">// ${todo} Auto-generated catch block\n${exception_var}.printStackTrace();</template><template autoinsert\="true" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">// ${todo} Auto-generated method stub\n${body_statement}</template><template autoinsert\="true" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}\n// ${todo} Auto-generated constructor stub</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates>
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.m2e.core.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.m2e.core.prefs
deleted file mode 100644
index f897a7f1cb2..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.m2e.core.prefs
+++ /dev/null
@@ -1,4 +0,0 @@
-activeProfiles=
-eclipse.preferences.version=1
-resolveWorkspaceProjects=true
-version=1
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.pde.api.tools.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644
index 23fb95e120f..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.pde.api.tools.prefs
+++ /dev/null
@@ -1,98 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Ignore
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_ANNOTATION=Ignore
-INVALID_JAVADOC_TAG=Ignore
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Ignore
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=Enabled
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Warning
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.core.Xtend.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.core.Xtend.prefs
deleted file mode 100644
index df3c3c49d40..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.core.Xtend.prefs
+++ /dev/null
@@ -1,6 +0,0 @@
-//outlet.DEFAULT_OUTPUT.sourceFolder.src/main/java.directory=xtend-gen
-BuilderConfiguration.is_project_specific=true
-eclipse.preferences.version=1
-outlet.DEFAULT_OUTPUT.hideLocalSyntheticVariables=true
-outlet.DEFAULT_OUTPUT.installDslAsPrimarySource=false
-outlet.DEFAULT_OUTPUT.userOutputPerSourceFolder=true
diff --git a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.shared.ui.prefs b/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.shared.ui.prefs
deleted file mode 100644
index 89103792688..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/.settings/org.eclipse.xtend.shared.ui.prefs
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-metamodelContributor=org.eclipse.xtend.typesystem.emf.ui.EmfMetamodelContributor,org.eclipse.xtend.typesystem.uml2.ui.Uml2MetamodelContributor
diff --git a/plugins/developer/org.eclipse.papyrus.def/META-INF/MANIFEST.MF b/plugins/developer/org.eclipse.papyrus.def/META-INF/MANIFEST.MF
deleted file mode 100644
index e14e7535af3..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,25 +0,0 @@
-Manifest-Version: 1.0
-Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.12.0,4.0.0)",
- org.eclipse.emf.ecore;bundle-version="[2.12.0,3.0.0)";visibility:=reexport,
- org.eclipse.emf.codegen.ecore;bundle-version="[2.12.0,3.0.0)";visibility:=reexport,
- org.eclipse.draw2d;bundle-version="[3.10.0,4.0.0)",
- org.eclipse.gmf.runtime.notation;bundle-version="[1.8.0,2.0.0)",
- org.eclipse.gmf.common;bundle-version="[1.3.0,2.0.0)";visibility:=reexport,
- org.eclipse.gmf.validate;bundle-version="[1.2.0,2.0.0)",
- org.eclipse.gmf.graphdef;bundle-version="[2.9.0,3.0.0)",
- org.eclipse.xtext;bundle-version="[2.10.0,3.0.0)",
- org.eclipse.xtext.builder;bundle-version="[2.10.0,3.0.0)",
- org.eclipse.xtend.lib;bundle-version="[2.10.0,3.0.0)",
- org.eclipse.gmf.codegen.xtend;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.papyrus.gmfgenextension;bundle-version="[2.0.0,3.0.0)",
- org.eclipse.gmf.runtime.emf.type.core;bundle-version="[1.9.0,2.0.0)",
- org.eclipse.papyrus.infra.types.core;bundle-version="[3.0.0,4.0.0)"
-Bundle-Vendor: %providerName
-Bundle-ClassPath: .
-Bundle-Version: 1.3.0.qualifier
-Bundle-Name: %pluginName
-Bundle-Localization: plugin
-Bundle-Activator: org.eclipse.gmf.codegen.util.DefaultActivator
-Bundle-ManifestVersion: 2
-Bundle-SymbolicName: org.eclipse.papyrus.def;singleton:=true
-Bundle-RequiredExecutionEnvironment: JavaSE-1.8
diff --git a/plugins/developer/org.eclipse.papyrus.def/about.html b/plugins/developer/org.eclipse.papyrus.def/about.html
deleted file mode 100644
index 23506a4bae1..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/about.html
+++ /dev/null
@@ -1,26 +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, 2006</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> \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/build.properties b/plugins/developer/org.eclipse.papyrus.def/build.properties
deleted file mode 100644
index 057f0ec72ef..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/build.properties
+++ /dev/null
@@ -1,11 +0,0 @@
-jars.compile.order=.
-source.. = xtend/,\
- xtend-gen/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- about.html,\
- plugin.properties,\
- xtend/,\
- xtend-gen/
-src.includes = about.html
diff --git a/plugins/developer/org.eclipse.papyrus.def/plugin.properties b/plugins/developer/org.eclipse.papyrus.def/plugin.properties
deleted file mode 100644
index 76b9bbd92d7..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/plugin.properties
+++ /dev/null
@@ -1,12 +0,0 @@
-#################################################################################
-# Copyright (c) 2008 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:
-# Patrick Tessier patrick.tessier@cea.fr - Initial API and implementation
-##################################################################################
-pluginName=Papyrus Templates Extension for GMF tooling
-providerName=Eclipse Modeling Project
diff --git a/plugins/developer/org.eclipse.papyrus.def/pom.xml b/plugins/developer/org.eclipse.papyrus.def/pom.xml
deleted file mode 100644
index 02c8550e469..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/pom.xml
+++ /dev/null
@@ -1,61 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <artifactId>org.eclipse.papyrus.developer</artifactId>
- <groupId>org.eclipse.papyrus</groupId>
- <version>0.0.1-SNAPSHOT</version>
- </parent>
- <artifactId>org.eclipse.papyrus.def</artifactId>
- <groupId>org.eclipse.papyrus</groupId>
- <version>1.3.0-SNAPSHOT</version>
- <packaging>eclipse-plugin</packaging>
-
- <properties>
- <project.build.sourceEncoding>ISO-8859-1</project.build.sourceEncoding>
- </properties>
-
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-clean-plugin</artifactId>
- <configuration>
- <filesets>
- <fileset>
- <directory>xtend-gen</directory>
- <includes>
- <include>**/*</include>
- </includes>
- <excludes>
- <exclude>.gitignore</exclude>
- </excludes>
- </fileset>
- </filesets>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.eclipse.xtend</groupId>
- <artifactId>xtend-maven-plugin</artifactId>
- <executions>
- <execution>
- <phase>generate-sources</phase>
- <goals>
- <goal>compile</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <outputDirectory>xtend-gen</outputDirectory>
- <testOutputDirectory>${project.build.directory}/xtend-gen/test</testOutputDirectory>
- <encoding>ISO-8859-1</encoding>
- </configuration>
- </plugin>
- </plugins>
- </build>
-</project>
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend-gen/.gitignore b/plugins/developer/org.eclipse.papyrus.def/xtend-gen/.gitignore
deleted file mode 100644
index c96a04f008e..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend-gen/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-*
-!.gitignore \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ChildNodeLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ChildNodeLabelEditPart.xtend
deleted file mode 100644
index cd724aac1d1..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ChildNodeLabelEditPart.xtend
+++ /dev/null
@@ -1,43 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenChildLabelNode
-import org.eclipse.papyrus.papyrusgmfgenextension.ExtendedGenView
-
-@Singleton class ChildNodeLabelEditPart extends diagram.editparts.ChildNodeLabelEditPart {
-
-
-
- override extendsList(GenChildLabelNode it) '''
-«««BEGIN: PapyrusGenCode
-«««Add own extension
-«IF it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v |v.genView.contains(it) && v.superOwnedEditPart!=null].size != 0»
-extends «FOR extendedObject : it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v |v.genView.contains(it) && v.superOwnedEditPart!=null].toIterable»
-«specifyInheritance(extendedObject as ExtendedGenView)»
-«ENDFOR»
-«««END: PapyrusGenCode
-«ELSE»
- extends org.eclipse.gmf.runtime.diagram.ui.editparts.CompartmentEditPart
-«ENDIF»
-'''
-
-//BEGIN: PapyrusGenCode
-//definition of the inheritance
-def specifyInheritance (ExtendedGenView it)'''«superOwnedEditPart»'''
-//END: PapyrusGenCode
-
-override implementsList(GenChildLabelNode it) '''implements org.eclipse.gmf.runtime.diagram.ui.editparts.ITextAwareEditPart, org.eclipse.gmf.runtime.diagram.ui.editparts.IPrimaryEditPart, org.eclipse.papyrus.infra.gmfdiag.common.editpart.IControlParserForDirectEdit'''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/CompartmentEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/CompartmentEditPart.xtend
deleted file mode 100644
index 1afae6e2876..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/CompartmentEditPart.xtend
+++ /dev/null
@@ -1,87 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenCompartment
-import org.eclipse.papyrus.papyrusgmfgenextension.ExtendedGenView
-import xpt.Common
-
-@Singleton class CompartmentEditPart extends diagram.editparts.CompartmentEditPart {
- @Inject extension Common;
-
- override extendsList(GenCompartment it) '''
-
-«««BEGIN: PapyrusGenCode
-«««Add own extension
-«IF it.eResource.allContents.filter(typeof(ExtendedGenView)).filter[v|v.genView.contains(it) && v.superOwnedEditPart != null].size != 0»
- extends «FOR extendedObject : it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v|v.genView.contains(it) && v.superOwnedEditPart != null].toIterable»
- «specifyInheritance(extendedObject as ExtendedGenView)»
-«ENDFOR»
-«««END: BEGIN: PapyrusGenCode
-«ELSE»
- extends «IF listLayout»org.eclipse.gmf.runtime.diagram.ui.editparts.ListCompartmentEditPart«ELSE»org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.linklf.LinkLFShapeCompartmentEditPart«ENDIF»
-«ENDIF»
- '''
-
- //BEGIN: PapyrusGenCode
- //definition of the inheritance
- def specifyInheritance(ExtendedGenView it) '''«superOwnedEditPart»'''
-
- //END: PapyrusGenCode
- override additions(GenCompartment it) '''
- «handleSize(it)»
- «refreshbound(it)»
- «refreshvisual(it)»
- '''
-
- def handleSize(GenCompartment it) '''
- «generatedMemberComment»
-protected void handleNotificationEvent(org.eclipse.emf.common.notify.Notification notification) {
- Object feature = notification.getFeature();
- if (org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getSize_Width().equals(feature)
- || org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getSize_Height().equals(feature)
- || org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLocation_X().equals(feature)
- || org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLocation_Y().equals(feature)) {
- refreshBounds();
- }
- super.handleNotificationEvent(notification);
- }
-'''
-
- def refreshbound(GenCompartment it) '''
- «generatedMemberComment»
- protected void refreshBounds() {
- int width = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getSize_Width())).intValue();
- int height = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getSize_Height())).intValue();
- org.eclipse.draw2d.geometry.Dimension size = new org.eclipse.draw2d.geometry.Dimension(width, height);
- int x = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLocation_X())).intValue();
- int y = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLocation_Y())).intValue();
- org.eclipse.draw2d.geometry.Point loc = new org.eclipse.draw2d.geometry.Point(x, y);
- ((org.eclipse.gef.GraphicalEditPart) getParent()).setLayoutConstraint(
- this,
- getFigure(),
- new org.eclipse.draw2d.geometry.Rectangle(loc, size));
- }
- '''
-
- def refreshvisual(GenCompartment it) '''
- «generatedMemberComment»
-protected void refreshVisuals() {
- super.refreshVisuals();
- refreshBounds();
- }
-'''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/DiagramEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/DiagramEditPart.xtend
deleted file mode 100644
index a6e7c02d13d..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/DiagramEditPart.xtend
+++ /dev/null
@@ -1,28 +0,0 @@
-/**
- * Copyright (c) 2006, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-
-@Singleton class DiagramEditPart extends diagram.editparts.DiagramEditPart {
-
- @Inject aspects.impl.diagram.editparts.DiagramEditPart aspectDiagramEditPart;
-
- //BEGIN: PapyrusGenCode
- //patches the super type of the diagram edit part in case the controlled object represents a UML element
- override extendsList(GenDiagram it) '''extends «aspectDiagramEditPart.extendsListContents(it)»'''
- //END: PapyrusGenCode
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ExternalNodeLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ExternalNodeLabelEditPart.xtend
deleted file mode 100644
index 604015ede6b..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/ExternalNodeLabelEditPart.xtend
+++ /dev/null
@@ -1,83 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenExternalNodeLabel
-import org.eclipse.papyrus.papyrusgmfgenextension.ExtendedGenView
-import org.eclipse.papyrus.papyrusgmfgenextension.LabelVisibilityPreference
-import xpt.Common
-
-@Singleton class ExternalNodeLabelEditPart extends diagram.editparts.ExternalNodeLabelEditPart {
- @Inject extension Common;
-
- override extendsList(GenExternalNodeLabel it) '''
- «««BEGIN: PapyrusGenCode
- «««specify a java super class for external nodes
- «IF it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v | v.genView.contains(it) && v.superOwnedEditPart != null].size != 0»
- extends «FOR extendedObject : it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v|v.genView.contains(it) && v.superOwnedEditPart != null].toIterable»
- «specifyInheritance(extendedObject as ExtendedGenView)»
- «ENDFOR»
- «««END: PapyrusGenCode
- «ELSE»
- extends org.eclipse.papyrus.infra.gmfdiag.common.editpart.PapyrusLabelEditPart
- «ENDIF»
- '''
-
- //we add the interface ILabelRoleProvider
- override implementsList(GenExternalNodeLabel it) '''
- implements org.eclipse.gmf.runtime.diagram.ui.editparts.ITextAwareEditPart, org.eclipse.gmf.runtime.diagram.ui.editparts.IBorderItemEditPart
- ««« BEGIN: PapyrusGenCode
- «IF it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v|v.externalNodeLabels.contains(it)].size != 0»
- , org.eclipse.papyrus.uml.diagram.common.editparts.ILabelRoleProvider
- «ENDIF»
- ««« END: PapyrusGenCode
- '''
-
- override additions(GenExternalNodeLabel it) '''
- ««« BEGIN: PapyrusGenCode
- «IF it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v|v.externalNodeLabels.contains(it)].size != 0»
- «generatedClassComment»
- public String getLabelRole(){
- return "«it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v|v.externalNodeLabels.contains(it)].head.role»";//$NON-NLS-1$
- }
-
- «generatedClassComment»
- public String getIconPathRole(){
- return "«it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v|v.externalNodeLabels.contains(it)].head.iconPathRole»";//$NON-NLS-1$
- }
- «ENDIF»
- ««« END: PapyrusGenCode
- '''
-
- def refreshBounds(GenExternalNodeLabel it) '''
- ««« BEGIN: PapyrusGenCode
- public void refreshBounds() {
- int x = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLocation_X())).intValue();
- int y = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLocation_Y())).intValue();
- int width = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getSize_Width())).intValue();
- int height = ((Integer) getStructuralFeatureValue(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getSize_Height())).intValue();
- getBorderItemLocator().setConstraint(new org.eclipse.draw2d.geometry.Rectangle(x, y, width, height));
- getBorderItemLocator().relocate(getFigure());
- }
- ««« END: PapyrusGenCode
- '''
-
- //BEGIN: PapyrusGenCode
- //definition of the inheritance
- def specifyInheritance(ExtendedGenView it) '''«superOwnedEditPart»'''
-
-//END: PapyrusGenCode
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkEditPart.xtend
deleted file mode 100644
index 5875e8c2c64..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkEditPart.xtend
+++ /dev/null
@@ -1,30 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-
-@Singleton class LinkEditPart extends diagram.editparts.LinkEditPart {
- @Inject aspects.impl.diagram.editparts.LinkEditPart aspectsLinkEditPart;
-
-
-
-//BEGIN: PapyrusGenCode
-//patches the super type of the link edit part in case the controlled object represents a UML element
-override extendsList(GenLink it) '''extends «aspectsLinkEditPart.extendsListContents(it)»'''
-//END: PapyrusGenCode
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend
deleted file mode 100644
index e4866434ac2..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/LinkLabelEditPart.xtend
+++ /dev/null
@@ -1,73 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.CustomBehaviour
-import org.eclipse.gmf.codegen.gmfgen.GenLinkLabel
-import org.eclipse.papyrus.papyrusgmfgenextension.LabelVisibilityPreference
-import xpt.Common
-
-@Singleton class LinkLabelEditPart extends diagram.editparts.LinkLabelEditPart{
- @Inject extension Common;
-
-
- override implementsList(GenLinkLabel it) '''
- implements org.eclipse.gmf.runtime.diagram.ui.editparts.ITextAwareEditPart, org.eclipse.papyrus.infra.gmfdiag.common.editpart.IControlParserForDirectEdit
- ««« BEGIN: PapyrusGenCode
- «IF it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v |v.linkLabels.contains(it)].size != 0»
- , org.eclipse.papyrus.uml.diagram.common.editparts.ILabelRoleProvider
- «ENDIF»
- ««« END: PapyrusGenCode
- '''
-
-
- override additions(GenLinkLabel it) '''
- ««« BEGIN: PapyrusGenCode
- «IF it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v | v.linkLabels.contains(it)].size != 0»
- «generatedClassComment»
- public String getLabelRole(){
- return "«it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v |v.linkLabels.contains(it)].head.role»";//$NON-NLS-1$
- }
-
- «generatedClassComment»
- public String getIconPathRole(){
- return "«it.eResource.allContents.filter(typeof (LabelVisibilityPreference)).filter[v |v.linkLabels.contains(it)].head.iconPathRole»";//$NON-NLS-1$
- }
- «ENDIF»
- ««« END: PapyrusGenCode
- '''
-
- override extendsList(GenLinkLabel it) '''extends org.eclipse.papyrus.infra.gmfdiag.common.editpart.PapyrusLabelEditPart'''
-
- override createDefaultEditPolicies(GenLinkLabel it) '''
- /**
- * @generated Papyrus Generation
- */
- @Override
- protected void createDefaultEditPolicies() {
- super.createDefaultEditPolicies();
- installEditPolicy(org.eclipse.gef.EditPolicy.DIRECT_EDIT_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.LabelDirectEditPolicy());
- installEditPolicy(org.eclipse.gef.EditPolicy.SELECTION_FEEDBACK_ROLE, new «diagram.getTextSelectionEditPolicyQualifiedClassName()»());
- ««« BEGIN: PapyrusGenCode
- installEditPolicy(org.eclipse.gef.EditPolicy.PRIMARY_DRAG_ROLE, new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.PapyrusLinkLabelDragPolicy());
- ««« END: PapyrusGenCode
- ««« Get the added custom behavoir
- «FOR CustomBehaviour:it.behaviour.filter(typeof (CustomBehaviour))»
- installEditPolicy(«CustomBehaviour.key», new «CustomBehaviour.editPolicyQualifiedClassName»());
- «ENDFOR»
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeEditPart.xtend
deleted file mode 100644
index d79b500c2ae..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeEditPart.xtend
+++ /dev/null
@@ -1,112 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import xpt.Common
-import xpt.diagram.editparts.Utils_qvto
-
-//DOCUMENTATION: PapyrusGenCode
-//add call template in order to generate handlenotification in order to refresh figure by taking account event
-
-@Singleton class NodeEditPart extends diagram.editparts.NodeEditPart {
- @Inject extension Common;
- @Inject extension Utils_qvto;
-
- @Inject impl.diagram.editparts.NodeEditPart xptNodeEditPartImpl;
- @Inject aspects.impl.diagram.editparts.NodeEditPart aspectsNodeEditPartImpl;
-
-
-
- override Main(GenNode it) '''
- «copyright(diagram.editorGen)»
- package «xptNodeEditPartImpl.packageName(it)»;
-
- «generatedClassComment»
- public class «xptNodeEditPartImpl.className(it)» «extendsList(it)» «implementsList(it)» {
-
- «attributes(it)»
-
- «xptNodeEditPartImpl.constructor(it)»
-
- «createDefaultEditPolicies(it)»
-
- «xptNodeEditPartImpl.createLayoutEditPolicy(it)»
-
-««« BEGIN: PapyrusGenCode
-««« call tamplate to paste code for refresh figure by taking account event
- «aspectsNodeEditPartImpl.specificHandleNotificationEvent(it)»
-««« END: PapyrusGenCode
-
- «xptNodeEditPartImpl.createNodeShape(it.viewmap, it)»
-
- «IF hasFixedChildren(it)»
- «xptNodeEditPartImpl.addFixedChild(it)»
-
- «xptNodeEditPartImpl.removeFixedChild(it)»
-
- «xptNodeEditPartImpl.addChildVisual(it)»
-
- «xptNodeEditPartImpl.removeChildVisual(it)»
-
- «xptNodeEditPartImpl.getContentPaneFor(it)»
- «ENDIF»
-
- «xptNodeEditPartImpl.addBorderItem(it)»
-
- «xptNodeEditPartImpl.createNodePlate(it)»
-
- «xptNodeEditPartImpl.getPrimaryDragEditPolicy(it)»
-
- «xptNodeEditPartImpl.createFigure(it)»
-
- «xptNodeEditPartImpl.setupContentPane(it)»
-
- «xptNodeEditPartImpl.getContentPane(it)»
-
- «xptNodeEditPartImpl.setForegroundColor(it)»
-
-««« «xptNodeEditPartImpl.setBackgroundColor(it)»
-
- «xptNodeEditPartImpl.setLineWidth(it)»
-
- «xptNodeEditPartImpl.setLineStyle(it)»
-
- «xptNodeEditPartImpl.getPrimaryChildEditPart(it)»
-
-
-
- «IF hasChildrenInListCompartments(it)»
- «xptNodeEditPartImpl.getTargetEditPartMethod(it)»
- «ENDIF»
-
- «handleNotificationEvent(it)»
-
- «xptNodeEditPartImpl.innerClassDeclaration(viewmap)»
-
- «additions(it)»
- }
- '''
-
- //BEGIN: PapyrusGenCode
- //patches the super type of the node edit part in case the controlled object represents a UML element
- override extendsList (GenNode it)''' extends «aspectsNodeEditPartImpl.extendsListContents(it)»'''
- //END: PapyrusGenCode
-
- // override additions(GenNode it) '''
- // «aspectsNodeEditPartImpl.genPreferredValue(it)»
- // '''
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeLabelEditPart.xtend
deleted file mode 100644
index effa52d178c..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/diagram/editparts/NodeLabelEditPart.xtend
+++ /dev/null
@@ -1,78 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenNodeLabel
-import xpt.Common
-
-//DOCUMENTATION: PapyrusGenCode
-//add in the addition codes in order to refresh the labels
-@Singleton class NodeLabelEditPart extends diagram.editparts.NodeLabelEditPart {
- @Inject extension Common;
-
- @Inject impl.diagram.editparts.NodeLabelEditPart xptNodeLabelEditPart;
-
-override implementsList(GenNodeLabel it)'''implements org.eclipse.gmf.runtime.diagram.ui.editparts.ITextAwareEditPart, org.eclipse.papyrus.infra.gmfdiag.common.editpart.IControlParserForDirectEdit'''
-
-//BEGIN: PapyrusGenCode
-//Definition of the inheritance
-override extendsList (GenNodeLabel it) '''extends org.eclipse.papyrus.infra.gmfdiag.common.editpart.PapyrusCompartmentEditPart'''
-//END: PapyrusGenCode
-
- override handleNotificationEvent(GenNodeLabel it) '''
- «generatedMemberComment»
- protected void handleNotificationEvent(org.eclipse.emf.common.notify.Notification event) {
- refreshLabel();
- «xptNodeLabelEditPart.handleNotificationEventBody(it)»
- }
- '''
-
- override additions(GenNodeLabel it) '''
- ««« Code to refresh icon
-
- «generatedMemberComment»
- private static final String ADD_PARENT_MODEL = "AddParentModel";
-
-
- «generatedMemberComment»
- public void activate() {
- super.activate();
- addOwnerElementListeners();
- }
-
- «generatedMemberComment»
- protected void addOwnerElementListeners() {
- addListenerFilter(ADD_PARENT_MODEL, this, ((org.eclipse.gmf.runtime.notation.View) getParent().getModel()));
-
- }
-
- «generatedMemberComment»
- public void deactivate() {
- removeOwnerElementListeners();
- super.deactivate();
-
- }
-
-
- «generatedMemberComment»
- protected void removeOwnerElementListeners() {
- removeListenerFilter(ADD_PARENT_MODEL);
-
- }
-
- «««END: PapyrusGenCode
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/actions/LoadResourceAction.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/actions/LoadResourceAction.xtend
deleted file mode 100755
index 5b903b1d792..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/actions/LoadResourceAction.xtend
+++ /dev/null
@@ -1,21 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 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:
- * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - Initial API and implementation
- *****************************************************************************/
-package aspects.impl.actions
-
-import com.google.inject.Singleton
-
-@Singleton class LoadResourceAction extends impl.actions.LoadResourceAction{
-
- override def extendsList(org.eclipse.gmf.codegen.gmfgen.LoadResourceAction it) //
- ''' extends org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.actions.DefaultLoadResourceAction'''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChildNodeLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChildNodeLabelEditPart.xtend
deleted file mode 100644
index aab60587751..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChildNodeLabelEditPart.xtend
+++ /dev/null
@@ -1,41 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenChildLabelNode
-import xpt.diagram.editparts.Common
-
-/**
- * Revisit: [MG]: @Inject extension same-named-api-class -> template extends api-class?
- */
-@Singleton class ChildNodeLabelEditPart extends impl.diagram.editparts.ChildNodeLabelEditPart {
- @Inject extension Common;
-
-
- override handleNotificationEventBody(GenChildLabelNode it) '''
- Object feature = event.getFeature();
- «handleText(it)»
- «IF labelElementIcon»
- if(event.getNewValue() instanceof org.eclipse.emf.ecore.EAnnotation && org.eclipse.papyrus.infra.emf.appearance.helper.VisualInformationPapyrusConstants.DISPLAY_NAMELABELICON.equals(((org.eclipse.emf.ecore.EAnnotation)event.getNewValue()).getSource())){
- refreshLabel();
- }
- «ENDIF»
- if (org.eclipse.uml2.uml.UMLPackage.eINSTANCE.getFeature_IsStatic().equals(feature)) {
- refreshUnderline();
- }
- super.handleNotificationEvent(event);
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChoiceUtils_qvto.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChoiceUtils_qvto.xtend
deleted file mode 100644
index 38e0ccecec7..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ChoiceUtils_qvto.xtend
+++ /dev/null
@@ -1,33 +0,0 @@
-/**
- * Copyright (c) 2011 - 2013 Montages AG
- *
- * 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:
- * Svyatoslav Kovalsky (Montages) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.LabelModelFacet
-import org.eclipse.gmf.codegen.gmfgen.OclChoiceParser
-import org.eclipse.gmf.codegen.gmfgen.PredefinedEnumParser
-import xpt.Common_qvto
-
-@Singleton class ChoiceUtils_qvto extends impl.diagram.editparts.ChoiceUtils_qvto {
- @Inject extension Common_qvto
-
- override boolean isChoiceLabel(LabelModelFacet modelFacet) {
- var parser = modelFacet.parser;
- if (parser != null) {
- return parser.oclIsKindOf(typeof(PredefinedEnumParser)) || parser.oclIsKindOf(typeof(OclChoiceParser));
- } else {
- return false;
- }
- }
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/CompartmentEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/CompartmentEditPart.xtend
deleted file mode 100644
index 8ec2edaf53e..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/CompartmentEditPart.xtend
+++ /dev/null
@@ -1,69 +0,0 @@
-/**
- * Copyright (c) 2006, 2009 Borland Software Corporation
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenCompartment
-import xpt.diagram.editparts.Common
-import org.eclipse.papyrus.papyrusgmfgenextension.ExtendedGenView
-
-//DOCUMENTATION: PapyrusGenCode
-//Overload only the creation of editPolicies in order to add the paste edit policy
-@Singleton class CompartmentEditPart extends impl.diagram.editparts.CompartmentEditPart {
- @Inject extension xpt.Common;
- @Inject Common xptEditpartsCommon;
-
-
-
- override createDefaultEditPoliciesBody(GenCompartment it) '''
- super.createDefaultEditPolicies();
- «IF canCollapse»
- installEditPolicy(org.eclipse.gef.EditPolicy.PRIMARY_DRAG_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.ResizableCompartmentEditPolicy());
- «ENDIF»
- «xptEditpartsCommon.installSemanticEditPolicy(it)»
- «IF ! childNodes.empty»
- installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.CREATION_ROLE, new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultCreationEditPolicy());
- installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.DRAG_DROP_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.DragDropEditPolicy());
- installEditPolicy(org.eclipse.papyrus.uml.diagram.common.editpolicies.PasteEditPolicy.PASTE_ROLE, new org.eclipse.papyrus.uml.diagram.common.editpolicies.PasteEditPolicy());
- «ENDIF»
- «xptEditpartsCommon.installCanonicalEditPolicy(it)»
- «xptEditpartsCommon.behaviour(it)»
- '''
-
- override getTargetEditPartMethod(GenCompartment it) '''
- «generatedMemberComment»
- public org.eclipse.gef.EditPart getTargetEditPart(org.eclipse.gef.Request request) {
-
- return super.getTargetEditPart(request);
- }
- '''
-
- override createFigure(GenCompartment it) {
- if (hasExternalSuperClass(it,'org.eclipse.papyrus.uml.diagram.activity.edit.part.ShapeCompartmentWithoutScrollbarsEditPart')) {
- '''
- @Override
- public org.eclipse.draw2d.IFigure createFigure() {
- return super.createFigure();
- }
- '''
- } else {
- super.createFigure(it);
- }
- }
-
- def boolean hasExternalSuperClass(GenCompartment it, String className) {
- return it.eResource.allContents.filter(typeof(ExtendedGenView)).filter [v | (v.genView.contains(it) && v.superOwnedEditPart.equals(className))].size > 0;
- }
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/DiagramEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/DiagramEditPart.xtend
deleted file mode 100644
index 44075206b8b..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/DiagramEditPart.xtend
+++ /dev/null
@@ -1,102 +0,0 @@
-/**
- * Copyright (c) 2006, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import xpt.diagram.commands.CreateShortcutDecorationsCommand
-import xpt.diagram.editparts.Common
-import xpt.diagram.editparts.Utils_qvto
-
-/**
- * Revisit: [MG]: @Inject extension same-named-api-class -> template extends api-class?
- */
-//DOCUMENTATION: PapyrusGencode
-//This template has been modify to allow the drag and drop
-@Singleton class DiagramEditPart extends impl.diagram.editparts.DiagramEditPart {
- @Inject extension MetaModel;
- @Inject extension Utils_qvto;
-
- @Inject Common xptEditpartsCommon;
- @Inject CreateShortcutDecorationsCommand createShoutrtcutDecorationCommand;
-
-//BEGIN: PapyrusGenCode
-//computes super type of the link edit part in case the edit part manages a representation of a UML element
-def extendsListContents(GenDiagram it)'''
-org.eclipse.papyrus.infra.gmfdiag.common.editpart.PapyrusDiagramEditPart
-'''
-//END: BEGIN: PapyrusGenCode
-
-override createDefaultEditPoliciesBody(GenDiagram it) '''
- super.createDefaultEditPolicies();
-
- installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.CREATION_ROLE, new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultCreationEditPolicy());
- installEditPolicy(org.eclipse.papyrus.uml.diagram.common.editpolicies.PasteEditPolicy.PASTE_ROLE, new org.eclipse.papyrus.uml.diagram.common.editpolicies.PasteEditPolicy());
-
- «xptEditpartsCommon.installSemanticEditPolicy(it)»
- «xptEditpartsCommon.installCanonicalEditPolicy(it)»
- ««« «xptEditpartsCommon.installCreationEditPolicy(it)»
- «IF generateCreateShortcutAction() && null == editorGen.application»
- installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.DRAG_DROP_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.DiagramDragDropEditPolicy() {
- public org.eclipse.gef.commands.Command getDropObjectsCommand(org.eclipse.gmf.runtime.diagram.ui.requests.DropObjectsRequest dropRequest) {
- java.util.List<org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequest.ViewDescriptor> viewDescriptors = new java.util.ArrayList<org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequest.ViewDescriptor>();
- for (java.util.Iterator<?> it = dropRequest.getObjects().iterator(); it.hasNext();) {
- Object nextObject = it.next();
- if (false == nextObject instanceof org.eclipse.emf.ecore.EObject) {
- continue;
- }
- viewDescriptors.add(new org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequest.ViewDescriptor(new org.eclipse.gmf.runtime.emf.core.util.EObjectAdapter((org.eclipse.emf.ecore.EObject) nextObject), org.eclipse.gmf.runtime.notation.Node.class, null, getDiagramPreferencesHint()));
- }
- return createShortcutsCommand(dropRequest, viewDescriptors);
- }
-
- private org.eclipse.gef.commands.Command createShortcutsCommand(org.eclipse.gmf.runtime.diagram.ui.requests.DropObjectsRequest dropRequest, java.util.List<org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewRequest.ViewDescriptor> viewDescriptors) {
- org.eclipse.gef.commands.Command command = createViewsAndArrangeCommand(dropRequest, viewDescriptors);
- if (command != null) {
- return command.chain(new org.eclipse.gmf.runtime.diagram.ui.commands.ICommandProxy(new «createShoutrtcutDecorationCommand.qualifiedClassName(it)»(getEditingDomain(), (org.eclipse.gmf.runtime.notation.View) getModel(), viewDescriptors)));
- }
- return null;
- }
- });
- «ENDIF»
- «IF shouldGenerateDiagramViewmap(it)»
- // diagram figure does layout; need to install child editpolicy to show selection feedback
- installEditPolicy(org.eclipse.gef.EditPolicy.LAYOUT_ROLE, new org.eclipse.gmf.runtime.diagram.ui.editpolicies.LayoutEditPolicy() {
- protected org.eclipse.gef.EditPolicy createChildEditPolicy(org.eclipse.gef.EditPart child) {
- final org.eclipse.gef.editpolicies.NonResizableEditPolicy p = new org.eclipse.gef.editpolicies.NonResizableEditPolicy();
- p.setDragAllowed(false);
- return p;
- }
- protected org.eclipse.gef.commands.Command getMoveChildrenCommand(org.eclipse.gef.Request request) {
- return null;
- }
- protected org.eclipse.gef.commands.Command getCreateCommand(org.eclipse.gef.requests.CreateRequest request) {
- return null;
- }
- });
- «ENDIF»
- «xptEditpartsCommon.behaviour(it)»
- // removeEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.POPUPBAR_ROLE);
-'''
-
-def featureForMetaclass (GenNode it)'''
- if (« MetaClass(modelFacet.metaClass)».equals(class1)) {
- return «MetaFeature(modelFacet.containmentMetaFeature)»;
- }
-'''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ExternalNodeLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ExternalNodeLabelEditPart.xtend
deleted file mode 100644
index a2dec74c795..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/ExternalNodeLabelEditPart.xtend
+++ /dev/null
@@ -1,30 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2014 CEA LIST and others.
- *
- * 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 aspects.impl.diagram.editparts
-
-import org.eclipse.gmf.codegen.gmfgen.GenExternalNodeLabel
-
-/**
- * @author Mickael ADAM
- *
- */
-class ExternalNodeLabelEditPart extends impl.diagram.editparts.ExternalNodeLabelEditPart {
-
- override additionalEditPolicies(GenExternalNodeLabel it){
- '''
- installEditPolicy(org.eclipse.gef.EditPolicy.PRIMARY_DRAG_ROLE, new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.ExternalLabelPrimaryDragRoleEditPolicy());
- '''
- }
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkEditPart.xtend
deleted file mode 100644
index 5fd8ade4588..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkEditPart.xtend
+++ /dev/null
@@ -1,118 +0,0 @@
-/**
- * Copyright (c) 2006, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Remi Schnekenburger (CEA LIST) - modification for Papyrus MDT
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.ModeledViewmap
-import org.eclipse.papyrus.papyrusgmfgenextension.ExtendedGenView
-import xpt.Common
-
-/**
- * Revisit: [MG]: @Inject extension same-named-api-class -> template extends api-class?
- */
-@Singleton class LinkEditPart extends impl.diagram.editparts.LinkEditPart {
- @Inject extension Common;
-
-
- //BEGIN: PapyrusGenCode
- //computes super type of the link edit part in case the edit part manages a representation of a UML element
- def extendsListContents(GenLink it)'''
- «IF it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v |(v.genView.contains(it) && v.superOwnedEditPart!=null)].size != 0»
- «FOR extendedObject : it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v |(v.genView.contains(it) && v.superOwnedEditPart!=null)].toIterable»
- «specifyInheritance(extendedObject)»
- «ENDFOR»
- «ELSE»
- org.eclipse.papyrus.infra.gmfdiag.common.editpart.ConnectionEditPart
- «ENDIF»
- '''
- //END: BEGIN: PapyrusGenCode
-
- //BEGIN: PapyrusGenCode
- //definition of the inheritance
- def specifyInheritance (ExtendedGenView it)'''«superOwnedEditPart»'''
- //END: PapyrusGenCode
-
- override addFixedChild (GenLink it)'''
- «IF labels.size > 0»
- «generatedMemberComment»
- protected boolean addFixedChild(org.eclipse.gef.EditPart childEditPart) {
- «FOR label : labels»
- «addLabel(label.viewmap,label)»
- «ENDFOR»
- return false;
- }
- «ENDIF»
-'''
-
- override removeFixedChild(GenLink it) '''
- «IF ! labels.empty»
- «generatedMemberComment»
- protected boolean removeFixedChild(org.eclipse.gef.EditPart childEditPart) {
- «FOR label : labels»
- «removeLabel(label.viewmap, label)»
- «ENDFOR»
- return false;
- }
- «ENDIF»
- '''
-
- override addChildVisual(GenLink it) '''
- «IF ! labels.empty»
- «generatedMemberComment»
- protected void addChildVisual(org.eclipse.gef.EditPart childEditPart, int index) {
- if (addFixedChild(childEditPart)) {
- return;
- }
- super.addChildVisual(childEditPart, -1);
- }
- «ENDIF»
- '''
-
- override removeChildVisual(GenLink it) '''
- «IF ! labels.empty»
- «generatedMemberComment»
- protected void removeChildVisual(org.eclipse.gef.EditPart childEditPart) {
- if (removeFixedChild(childEditPart)) {
- return;
- }
- super.removeChildVisual(childEditPart);
- }
- «ENDIF»
- '''
-
- override dispatch createLinkFigure(ModeledViewmap it, GenLink link) '''
-««« «generatedMemberComment»
-««« protected org.eclipse.draw2d.Connection createConnectionFigure() {
-««« return new «modeledViewmapFigureFQN(it)»();
-««« }
-«««
-««« «generatedMemberComment»
-««« public «modeledViewmapFigureFQN(it)» getPrimaryShape() {
-««« return («modeledViewmapFigureFQN(it)») getFigure();
-««« }
-«««
-««« «xptModeledViewmapProducer.viewmapClassBody(it)»
- '''
-
- override modeledViewmapFigureFQN(ModeledViewmap it) '''
-««« «xptModeledViewmapProducer.viewmapFigureFQN(it)»
- '''
-
-}
-
-
-
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkLabelEditPart.xtend
deleted file mode 100644
index 6c1be9c56b0..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/LinkLabelEditPart.xtend
+++ /dev/null
@@ -1,47 +0,0 @@
-/**
- * Copyright (c) 2006, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Thibault Landre (Atos Origin) - initial API and implementation
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenLinkLabel
-import xpt.diagram.editparts.Common
-
-//DOCUMENTATION: PapyrusGencode
-//Overlaod only the method handlenotificationEventBody
-
-@Singleton class LinkLabelEditPart extends impl.diagram.editparts.LinkLabelEditPart {
- @Inject extension Common;
-
- override handleNotificationEventBody(GenLinkLabel it) '''
- Object feature = event.getFeature();
- «handleText (it)»
-
- ««« START Papyrus Code
- «IF elementIcon»
- if(event.getNewValue() instanceof org.eclipse.emf.ecore.EAnnotation && org.eclipse.papyrus.infra.emf.appearance.helper.VisualInformationPapyrusConstants.DISPLAY_NAMELABELICON.equals(((org.eclipse.emf.ecore.EAnnotation)event.getNewValue()).getSource())){
- refreshLabel();
- }
- «ENDIF»
- ««« End Papyrus Code
- super.handleNotificationEvent(event);
- '''
-
- override additionalEditPolicies(GenLinkLabel it)
- '''
- installEditPolicy(EditPolicy.PRIMARY_DRAG_ROLE, new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.PapyrusLinkLabelDragPolicy());
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeEditPart.xtend
deleted file mode 100644
index 78cc989408a..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeEditPart.xtend
+++ /dev/null
@@ -1,489 +0,0 @@
-/**
- * Copyright (c) 2006, 2014 Borland Software Corporation, Christian W. Damus, and others.
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Patrick Tessier (CEA) - initial API and implementation
- * Thibault Landre (Atos Origin) - initial API and implementation
- * Vincent Lorenzo (CEA-LIST) - Bug 335987 [General][Enhancement] Show/Hide Connectors Labels and External Nodes Labels
- * Christian W. Damus - bug 451230
- */
-package aspects.impl.diagram.editparts
-
-import aspects.xpt.editor.VisualIDRegistry
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenChildSideAffixedNode
-import org.eclipse.gmf.codegen.gmfgen.GenCommonBase
-import org.eclipse.gmf.codegen.gmfgen.GenExternalNodeLabel
-import org.eclipse.gmf.codegen.gmfgen.GenNavigatorChildReference
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import org.eclipse.gmf.codegen.gmfgen.ParentAssignedViewmap
-import org.eclipse.gmf.codegen.gmfgen.ToolEntry
-import org.eclipse.papyrus.papyrusgmfgenextension.ExtendedGenView
-import org.eclipse.papyrus.papyrusgmfgenextension.PropertyRefreshHook
-import org.eclipse.papyrus.papyrusgmfgenextension.SpecificLocator
-import utils.EditPartsUtils_qvto
-import xpt.Common
-import xpt.diagram.editparts.EditPartFactory
-import xpt.diagram.editparts.Utils_qvto
-import xpt.CodeStyle
-import xpt.diagram.ViewmapAttributesUtils_qvto
-import org.eclipse.papyrus.papyrusgmfgenextension.SpecificNodePlate
-import xpt.providers.ElementTypes
-
-@Singleton class NodeEditPart extends impl.diagram.editparts.NodeEditPart {
- @Inject extension Common;
- @Inject extension CodeStyle
-
- @Inject extension EditPartsUtils_qvto;
- @Inject extension VisualIDRegistry;
-
- @Inject extension ViewmapAttributesUtils_qvto;
-
- @Inject extension Utils_qvto;
- @Inject extension xpt.diagram.Utils_qvto;
- @Inject EditPartFactory xptEditPartFactory;
- @Inject impl.diagram.editparts.TextAware xptTextAware;
-
- @Inject VisualIDRegistry xptVisualIDRegistry;
- @Inject ElementTypes xptElementTypes;
-
-//---------
-// GMF
-//---------
-
- override dispatch extendsListContents (GenNode it)'''
-«««BEGIN: PapyrusGenCode
-«««Add own extension
-«IF it.eResource.allContents.filter(typeof(ExtendedGenView)).filter[v |v.genView.contains(it) && v.superOwnedEditPart!=null].size != 0»
-«FOR extendedObject : it.eResource.allContents.filter(typeof(ExtendedGenView)).filter[v |v.genView.contains(it) && v.superOwnedEditPart!=null].toIterable»
-«specifyInheritance(extendedObject as ExtendedGenView)»
-«ENDFOR»
-«««END: BEGIN: PapyrusGenCode
-«ELSE»
- org.eclipse.papyrus.infra.gmfdiag.common.editpart.NodeEditPart
-«ENDIF»
-'''
-
-override dispatch extendsListContents (GenChildSideAffixedNode it)'''
-«««BEGIN: PapyrusGenCode
-«««Add own extension
-«IF it.eResource.allContents.filter(typeof(ExtendedGenView)).filter[v |v.genView.contains(it) && v.superOwnedEditPart!=null].size != 0»
-«FOR extendedObject : it.eResource.allContents.filter(typeof(ExtendedGenView)).filter[v |v.genView.contains(it) && v.superOwnedEditPart!=null].toIterable»
-«specifyInheritance(extendedObject)»
-«ENDFOR»
-«««END: BEGIN: PapyrusGenCode
-«ELSE»
- «IF hasBorderItems(it)»org.eclipse.gmf.runtime.diagram.ui.editparts.BorderedBorderItemEditPart«ELSE»org.eclipse.gmf.runtime.diagram.ui.editparts.AbstractBorderItemEditPart«ENDIF»
-«ENDIF»
-'''
-override addFixedChild (GenNode it)'''
- «generatedMemberComment»
- protected boolean addFixedChild(org.eclipse.gef.EditPart childEditPart) {
-«FOR label:getInnerFixedLabels(it)»«var childViewmap = label.viewmap as ParentAssignedViewmap»
- if (childEditPart instanceof «xptEditPartFactory.getEditPartQualifiedClassName(label)») {
- ((«xptEditPartFactory.getEditPartQualifiedClassName(label)») childEditPart).«xptTextAware.labelSetterName(childViewmap)»(getPrimaryShape().«childViewmap.getterName»());
- return true;
- }
-«ENDFOR»
-
-«FOR compartment : getPinnedCompartments(it)»«var childViewmap = compartment.viewmap as ParentAssignedViewmap»
-
- if (childEditPart instanceof «compartment.getEditPartQualifiedClassName()») {
- org.eclipse.draw2d.IFigure pane = getPrimaryShape().«childViewmap.getterName»();
- setupContentPane(pane); // FIXME each comparment should handle his content pane in his own way
- pane.add(((«compartment.getEditPartQualifiedClassName()») childEditPart).getFigure());
- return true;
- }
-«ENDFOR»
-
-«FOR child:getSideAffixedChildren(it)»
- ««« BEGIN PapyrusGencode
- ««« adding IF else end in order to take in account the case where a specific locator is added
-
-
- «IF it.eResource.allContents.filter(typeof (SpecificLocator)).filter[v | v.genChildSideAffixedNode.contains(child)].size !=0»
- «FOR extendedObject : it.eResource.allContents.filter(typeof (SpecificLocator)).filter[v |v.genChildSideAffixedNode.contains(child)].toIterable»
- «genSpecificLocator(extendedObject,child)»
- «ENDFOR»
-
- «ELSE»
- «««END PapyrusGencode«ENDREM
- if (childEditPart instanceof «child.getEditPartQualifiedClassName()») {
- org.eclipse.gmf.runtime.diagram.ui.figures.BorderItemLocator locator = new org.eclipse.gmf.runtime.diagram.ui.figures.BorderItemLocator(getMainFigure(), org.eclipse.draw2d.PositionConstants.«child.preferredSideName»);
- getBorderedFigure().getBorderItemContainer().add(((«child.getEditPartQualifiedClassName()») childEditPart).getFigure(), locator);
- return true;
- }
- ««« BEGIN PapyrusGencode
- «ENDIF»
- «««END PapyrusGencode
-«ENDFOR»
- return false;
- }
-'''
-
- override installGraphicalNodeEditPolicy(GenNode it) '''
-
- installEditPolicy(org.eclipse.gef.EditPolicy.GRAPHICAL_NODE_ROLE, new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultGraphicalNodeEditPolicy());
-
- '''
-
- override def setLineWidth(GenNode it) '''
- «generatedMemberComment»
- protected void setLineWidth(int width) {
-««« if (primaryShape instanceof org.eclipse.gmf.runtime.gef.ui.figures.NodeFigure) {
-««« ((org.eclipse.gmf.runtime.gef.ui.figures.NodeFigure) primaryShape).setLineWidth(«IF getDiagram().isPixelMapMode()»width«ELSE»getMapMode().DPtoLP(width)«ENDIF»);
-««« }
- super.setLineWidth(width);
- }
- '''
-
- override def setLineStyle(GenNode it) '''
- «generatedMemberComment»
- protected void setLineType(int style) {
- if (primaryShape instanceof org.eclipse.papyrus.infra.gmfdiag.common.figure.node.IPapyrusNodeFigure) {
- ((org.eclipse.papyrus.infra.gmfdiag.common.figure.node.IPapyrusNodeFigure) primaryShape).setLineStyle(style);
- }
- }
- '''
-
- override createFigure(GenNode it) '''
- «generatedMemberComment(
- 'Creates figure for this edit part.\n' +
- '\n' +
- 'Body of this method does not depend on settings in generation model\n' +
- 'so you may safely remove <i>generated</i> tag and modify it.\n'
- )»
- protected org.eclipse.gmf.runtime.gef.ui.figures.NodeFigure create«IF hasBorderItems(it)»Main«ELSE»Node«ENDIF»Figure() {
- «IF it instanceof GenChildSideAffixedNode»
- org.eclipse.gmf.runtime.gef.ui.figures.NodeFigure figure = createNodePlate();
- figure.setLayoutManager(new org.eclipse.draw2d.StackLayout());
- org.eclipse.draw2d.IFigure shape = createNodeShape();
- figure.add(shape);
- contentPane = setupContentPane(shape);
- return figure;
- «ELSE»
- return new org.eclipse.papyrus.infra.gmfdiag.common.figure.node.SelectableBorderedNodeFigure(createMainFigureWithSVG());
- «ENDIF»
-
- }
- '''
-
-// override createNodePlate (GenNode it)'''
-// «generatedMemberComment»
-// protected org.eclipse.gmf.runtime.gef.ui.figures.NodeFigure createNodePlate() {
-// String prefElementId="«elementType.displayName»";
-// org.eclipse.jface.preference.IPreferenceStore store =«getDiagram().editorGen.plugin.getActivatorQualifiedClassName()».getInstance().getPreferenceStore();
-// String preferenceConstantWitdh=org.eclipse.papyrus.uml.diagram.common.helper.PreferenceInitializerForElementHelper.getpreferenceKey(getNotationView(), prefElementId, org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.WIDTH);
-// String preferenceConstantHeight=org.eclipse.papyrus.uml.diagram.common.helper.PreferenceInitializerForElementHelper.getpreferenceKey(getNotationView(), prefElementId, org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.HEIGHT);
-// org.eclipse.gmf.runtime.gef.ui.figures.DefaultSizeNodeFigure result = new org.eclipse.gmf.runtime.gef.ui.figures.DefaultSizeNodeFigure(store.getInt(preferenceConstantWitdh), store.getInt(preferenceConstantHeight));
-//
-// «setupNodePlate(it)»
-// return result;
-// }
-// '''
-
- override createNodePlate(GenNode it) '''
- «generatedMemberComment»
- «IF it.eResource.allContents.filter(typeof(SpecificNodePlate)).filter[v |v.editParts.contains(it) && v.nodePlateQualifiedName!=null].size != 0»
- «val editPart = it.eResource.allContents.filter(typeof(SpecificNodePlate)).filter[v |v.editParts.contains(it) && v.nodePlateQualifiedName!=null].head»
- protected org.eclipse.gmf.runtime.gef.ui.figures.NodeFigure createNodePlate() {
- «editPart.nodePlateQualifiedName» result = new «editPart.nodePlateQualifiedName»(«IF getDiagram().isPixelMapMode()»«defaultSizeWidth(viewmap, 40)», «defaultSizeHeight(viewmap, 40)»«ELSE»getMapMode().DPtoLP(«defaultSizeWidth(viewmap, 40)»), getMapMode().DPtoLP(«defaultSizeHeight(viewmap, 40)»)«ENDIF»);
- «setupNodePlate»
- return result;
- }
- «««END: BEGIN: PapyrusGenCode
- «ELSE»
- ««« «super.createNodePlate(it)»
- ««« By default node edit part are now RoundedRectangleNodePlateFigure
- protected org.eclipse.gmf.runtime.gef.ui.figures.NodeFigure createNodePlate() {
- org.eclipse.papyrus.infra.gmfdiag.common.figure.node.RoundedRectangleNodePlateFigure result = new org.eclipse.papyrus.infra.gmfdiag.common.figure.node.RoundedRectangleNodePlateFigure(«IF getDiagram().isPixelMapMode()»«defaultSizeWidth(viewmap, 40)», «defaultSizeHeight(viewmap, 40)»«ELSE»getMapMode().DPtoLP(«defaultSizeWidth(viewmap, 40)»), getMapMode().DPtoLP(«defaultSizeHeight(viewmap, 40)»)«ENDIF»);
- «setupNodePlate»
- return result;
- }
- «ENDIF»
- '''
-
-override borderItemSelectionEditPolicy(GenNode it)'''
- «IF hasBorderItems(it)»
- org.eclipse.gmf.runtime.notation.View childView = (org.eclipse.gmf.runtime.notation.View) child.getModel();
- String vid = «getVisualIDMethodCall(getDiagram())»(childView);
- if (vid != null) {
- switch (vid) {
- «IF getExternalLabels(it).size > 0»
- «FOR nextLabel : getExternalLabels(it) »
- «caseVisualID(nextLabel)»
- «ENDFOR»
- return «borderItemSelectionEP(it)»;
- «ENDIF»
- «IF getSideAffixedChildren(it).size > 0»
- «FOR nextBorderItem : getSideAffixedChildren(it)»
- «caseVisualID(nextBorderItem)»
- «ENDFOR»
- ««« BEGIN PapyrusGenCode
- ««« The purprose is to add replace GMF edit prolicy by an new editPolicy that allows to resize BorderItem
- return new org.eclipse.papyrus.uml.diagram.common.editpolicies.BorderItemResizableEditPolicy();
- ««« END PapyrusGenCode
- «ENDIF»
- }
- }
-«ENDIF»
-'''
-
- override createLayoutEditPolicyBody_FLOW_LAYOUT(GenNode it) '''
- org.eclipse.gmf.runtime.diagram.ui.editpolicies.FlowLayoutEditPolicy lep = new org.eclipse.gmf.runtime.diagram.ui.editpolicies.FlowLayoutEditPolicy() {
- «IF hasBorderItems(it)»
- «extraLineBreak»
- «overrideC»
- protected org.eclipse.gef.EditPolicy createChildEditPolicy(org.eclipse.gef.EditPart child) {
- «borderItemSelectionEditPolicy()»
- return super.createChildEditPolicy(child);
- }
- «ENDIF»
-
- «overrideC»
- protected org.eclipse.gef.commands.Command createAddCommand(org.eclipse.gef.EditPart child, org.eclipse.gef.EditPart after) {
- return null;
- }
-
- «overrideC»
- protected org.eclipse.gef.commands.Command createMoveChildCommand(org.eclipse.gef.EditPart child, org.eclipse.gef.EditPart after) {
- return null;
- }
-
- «overrideC»
- protected org.eclipse.gef.commands.Command getCreateCommand(org.eclipse.gef.requests.CreateRequest request) {
- return null;
- }
- };
- return lep;
- '''
-
- override createLayoutEditPolicyBody_DEFAULT(GenNode it) '''
- org.eclipse.gmf.runtime.diagram.ui.editpolicies.LayoutEditPolicy lep = new org.eclipse.gmf.runtime.diagram.ui.editpolicies.LayoutEditPolicy() {
-
- «overrideC»
- protected org.eclipse.gef.EditPolicy createChildEditPolicy(org.eclipse.gef.EditPart child) {
- «borderItemSelectionEditPolicy(it)»
- org.eclipse.gef.EditPolicy result = child.getEditPolicy(org.eclipse.gef.EditPolicy.PRIMARY_DRAG_ROLE);
- if (result == null) {
- result = new org.eclipse.gef.editpolicies.NonResizableEditPolicy();
- }
- return result;
- }
-
- «overrideC»
- protected org.eclipse.gef.commands.Command getMoveChildrenCommand(org.eclipse.gef.Request request) {
- return null;
- }
-
- «overrideC»
- protected org.eclipse.gef.commands.Command getCreateCommand(org.eclipse.gef.requests.CreateRequest request) {
- return null;
- }
- };
- return lep;
- '''
-
-//---------
-// PAPYRUS
-//---------
-
-//BEGIN: PapyrusGenCode
-//definition of the inheritance
-def specifyInheritance (ExtendedGenView it)'''«superOwnedEditPart»'''
-//END: PapyrusGenCode
-
-
-def genSpecificLocator(GenCommonBase it, GenChildSideAffixedNode child) ''''''
-
-def genSpecificLocator(ToolEntry it, GenChildSideAffixedNode child) ''''''
-
-def genSpecificLocator(GenNavigatorChildReference it,GenChildSideAffixedNode child)''''''
-
-def genSpecificLocator(SpecificLocator it, GenChildSideAffixedNode child)'''
-//Papyrus Gencode :«it.comment»
- if (childEditPart instanceof «child.getEditPartQualifiedClassName()») {
- org.eclipse.gmf.runtime.diagram.ui.figures.IBorderItemLocator locator = new «it.classpath»(getMainFigure(), org.eclipse.draw2d.PositionConstants.«child.preferredSideName»);
- getBorderedFigure().getBorderItemContainer().add(((«child.getEditPartQualifiedClassName()») childEditPart).getFigure(), locator);
- return true;
- }
-
-'''
-
- override def borderItemSelectionEP(GenNode it) '''
- new org.eclipse.gmf.runtime.diagram.ui.editpolicies.BorderItemSelectionEditPolicy() {
-
- «overrideC»
- protected java.util.List<?> createSelectionHandles() {
- org.eclipse.gef.handles.MoveHandle mh = new org.eclipse.gef.handles.MoveHandle((org.eclipse.gef.GraphicalEditPart) getHost());
- mh.setBorder(null);
- return java.util.Collections.singletonList(mh);
- }
- }
- '''
-
-//BEGIN PapyrusGencode
-//Overwrite an existing method to set the preference value in the editpart
-//def genPreferredValue (GenNode it)'''
-//
-// «generatedMemberComment»
-// @Override
-// public Object getPreferredValue(org.eclipse.emf.ecore.EStructuralFeature feature) {
-// org.eclipse.jface.preference.IPreferenceStore preferenceStore = (org.eclipse.jface.preference.IPreferenceStore) getDiagramPreferencesHint()
-// .getPreferenceStore();
-// Object result = null;
-//
-// if(feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLineStyle_LineColor() || feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFontStyle_FontColor() || feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFillStyle_FillColor()){
-// String prefColor = null;
-// if (feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getLineStyle_LineColor()) {
-// prefColor = org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.getElementConstant("«elementType.displayName»", org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.COLOR_LINE);
-// } else if (feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFontStyle_FontColor()) {
-// prefColor = org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.getElementConstant("«elementType.displayName»", org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.COLOR_FONT);
-// } else if (feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFillStyle_FillColor()) {
-// prefColor = org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.getElementConstant("«elementType.displayName»", org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.COLOR_FILL);
-// }
-// result = org.eclipse.gmf.runtime.draw2d.ui.figures.FigureUtilities
-// .RGBToInteger(org.eclipse.jface.preference.PreferenceConverter
-// .getColor(
-// (org.eclipse.jface.preference.IPreferenceStore) preferenceStore, prefColor));
-// } else if (feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFillStyle_Transparency() || feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFillStyle_Gradient()) {
-// String prefGradient = org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.getElementConstant("«elementType.displayName»", org.eclipse.papyrus.infra.gmfdiag.common.preferences.PreferencesConstantsHelper.COLOR_GRADIENT);
-// org.eclipse.papyrus.infra.gmfdiag.preferences.utils.GradientPreferenceConverter gradientPreferenceConverter = new org.eclipse.papyrus.infra.gmfdiag.preferences.utils.GradientPreferenceConverter(
-// preferenceStore.getString(prefGradient));
-// if(feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFillStyle_Transparency()){
-// result = new Integer(gradientPreferenceConverter
-// .getTransparency());
-// } else if (feature == org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE
-// .getFillStyle_Gradient()){
-// result = gradientPreferenceConverter.getGradientData();
-// }
-// }
-//
-// if(result == null){
-// result = getStructuralFeatureValue(feature);
-// }
-// return result;
-// }
-//'''
-//END PapyrusGencode
-
-//BEGIN: PapyrusGenCode
-//CreateGenerator to refresh figure by taking account of event of UML element or graphical element
-def specificHandleNotificationEvent (GenNode it) '''
-
- «IF it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v |v.genView.contains(it)].size != 0»
- /**
- *Papyrus codeGen
- *@generated
- **/
- protected void handleNotificationEvent(org.eclipse.emf.common.notify.Notification event) {
- «IF it.labels.filter(typeof(GenExternalNodeLabel)).size != 0»
- /*
- * when a node have external node labels, the methods refreshChildren() remove the EditPart corresponding to the Label from the EditPart
- * Registry. After that, we can't reset the visibility to true (using the Show/Hide Label Action)!
- */
- if(org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getView_Visible().equals(event.getFeature())) {
- Object notifier = event.getNotifier();
- java.util.List<?> modelChildren = ((org.eclipse.gmf.runtime.notation.View)getModel()).getChildren();
- if (false == notifier instanceof org.eclipse.gmf.runtime.notation.Edge
- ««« see Bug 463769
- && false == notifier instanceof org.eclipse.gmf.runtime.notation.BasicCompartment) {
- if(modelChildren.contains(event.getNotifier())) {
- return;
- }
- }
- }
- «ENDIF»
- super.handleNotificationEvent(event);
- «FOR extendedObject : it.eResource.allContents.filter(typeof (ExtendedGenView)).filter[v |v.genView.contains(it)].toIterable»
- «IF extendedObject.propRefreshHook !=null»
- «specificHandleNotificationEventBody(extendedObject.propRefreshHook)»
- «ENDIF»
- «ENDFOR»
-
- }
- «ENDIF»
-
-'''
-
-def specificHandleNotificationEventBody(PropertyRefreshHook it)'''
-«IF (it.comment !=null)»
-//«it.comment»
-«ENDIF»
-if (resolveSemanticElement() != null) {
-if(«it.triggeringCondition»){
- «it.action»;
- refreshVisuals();
-}
-}
-'''
-//END: PapyrusGenCode
-
-override addBorderItem (GenNode it)'''
- «IF getExternalLabels(it).size > 0»
- «generatedMemberComment»
- protected void addBorderItem(org.eclipse.draw2d.IFigure borderItemContainer, org.eclipse.gmf.runtime.diagram.ui.editparts.IBorderItemEditPart borderItemEditPart) {
- «IF getExternalLabelsWithoutSpecificLocator(it).size > 0»
- if («FOR label : getExternalLabelsWithoutSpecificLocator(it) SEPARATOR ' || '»borderItemEditPart instanceof «label.getEditPartQualifiedClassName()»«ENDFOR») {
- org.eclipse.gmf.runtime.diagram.ui.figures.BorderItemLocator locator = new org.eclipse.gmf.runtime.diagram.ui.figures.BorderItemLocator(getMainFigure(), org.eclipse.draw2d.PositionConstants.SOUTH);
- locator.setBorderItemOffset(new org.eclipse.draw2d.geometry.Dimension(-20, -20));
- borderItemContainer.add(borderItemEditPart.getFigure(), locator);
- } else
- «ENDIF»
- «FOR label : getExternalLabelsWithSpecificLocator(it)»
- if (borderItemEditPart instanceof «label.getEditPartQualifiedClassName()») {
- org.eclipse.gmf.runtime.diagram.ui.figures.IBorderItemLocator locator = new «getSpecificLocator(label)»(getMainFigure());
- borderItemContainer.add(borderItemEditPart.getFigure(), locator);
- } else
- «ENDFOR»
- {
- super.addBorderItem(borderItemContainer, borderItemEditPart);
- }
- }
- «ENDIF»
-'''
-
-override setupNodePlate (GenNode it) ''''''
-
-def setupNodePlate (GenChildSideAffixedNode it)'''
- //FIXME: workaround for #154536
- result.getBounds().setSize(result.getPreferredSize());
-'''
-
-override def getTargetEditPartMethod(GenNode it) '''
- «generatedMemberComment»
- public org.eclipse.gef.EditPart getTargetEditPart(org.eclipse.gef.Request request) {
- if (request instanceof org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewAndElementRequest) {
- org.eclipse.gmf.runtime.diagram.core.edithelpers.CreateElementRequestAdapter adapter = ((org.eclipse.gmf.runtime.diagram.ui.requests.CreateViewAndElementRequest) request).getViewAndElementDescriptor().getCreateElementRequestAdapter();
- org.eclipse.gmf.runtime.emf.type.core.IElementType type = (org.eclipse.gmf.runtime.emf.type.core.IElementType) adapter.getAdapter(org.eclipse.gmf.runtime.emf.type.core.IElementType.class);
- «FOR compartment : compartments»
- «IF listCompartmentHasChildren(compartment)»
- «FOR childNode : compartment.childNodes»
- if («xptElementTypes.className(it.diagram)».isKindOf(type, «xptElementTypes.accessElementType(childNode)»)) {
- return getChildBySemanticHint(«xptVisualIDRegistry.typeMethodCall(compartment)»);
- }
- «ENDFOR»
- «ENDIF»
- «ENDFOR»
- }
- return super.getTargetEditPart(request);
- }
-'''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeLabelEditPart.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeLabelEditPart.xtend
deleted file mode 100644
index 5e0d1cb8524..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/NodeLabelEditPart.xtend
+++ /dev/null
@@ -1,49 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Thibault Landre (Atos Origin) - initial API and implementation
- * Benoit Maggi (CEA LIST) -#510281 change dependency to replace gmft-runtime
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenNodeLabel
-import xpt.diagram.editparts.Common
-import xpt.diagram.editparts.Utils_qvto
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-
-@Singleton class NodeLabelEditPart extends impl.diagram.editparts.NodeLabelEditPart {
- @Inject extension Utils_qvto;
-
- @Inject Common xptEditpartsCommon;
-
- override def nodeLabelDragPolicyQualifiedClassName(GenDiagram it) '''org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.edit.policies.DefaultNodeLabelDragPolicy'''
-
-
- override handleNotificationEventBody(GenNodeLabel it) '''
- Object feature = event.getFeature();
- «IF isStoringChildPositions(node)»
- «xptEditpartsCommon.handleBounds(it)»
- «ENDIF»
- «xptEditpartsCommon.handleText(it)»
- ««« START Papyrus Code
- «IF elementIcon»
- if(event.getNewValue() instanceof org.eclipse.emf.ecore.EAnnotation && org.eclipse.papyrus.infra.emf.appearance.helper.VisualInformationPapyrusConstants.DISPLAY_NAMELABELICON.equals(((org.eclipse.emf.ecore.EAnnotation)event.getNewValue()).getSource())){
- refreshLabel();
- }
- «ENDIF»
- ««« End Papyrus Code
- super.handleNotificationEvent(event);
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend
deleted file mode 100644
index 6dc08068748..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/editparts/TextAware.xtend
+++ /dev/null
@@ -1,826 +0,0 @@
-/**
- * Copyright (c) 2006-2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.DesignLabelModelFacet
-import org.eclipse.gmf.codegen.gmfgen.GenCommonBase
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import org.eclipse.gmf.codegen.gmfgen.GenExternalNodeLabel
-import org.eclipse.gmf.codegen.gmfgen.GenLinkLabel
-import org.eclipse.gmf.codegen.gmfgen.LabelModelFacet
-import org.eclipse.gmf.codegen.gmfgen.ParentAssignedViewmap
-import org.eclipse.gmf.codegen.gmfgen.Viewmap
-import xpt.CodeStyle
-import xpt.Common
-import xpt.Common_qvto
-import xpt.diagram.ViewmapAttributesUtils_qvto
-import xpt.providers.ElementTypes
-
-//DOCUMENTATION: PapyrusGencode
-//This template has been modified to take in account the possibility to have extended direct editors
-
-@Singleton class TextAware extends impl.diagram.editparts.TextAware {
- @Inject extension Common
-
- @Inject extension CodeStyle
-
- @Inject extension ViewmapAttributesUtils_qvto
-
- @Inject extension Common_qvto
-
- @Inject ElementTypes xptElementTypes;
-
- override fields(GenCommonBase it)'''
- «generatedMemberComment»
- private org.eclipse.gef.tools.DirectEditManager manager;
-
- «generatedMemberComment»
- private org.eclipse.gmf.runtime.common.ui.services.parser.IParser parser;
-
- «generatedMemberComment»
- private java.util.List<?> parserElements;
-
- «generatedMemberComment»
- private String defaultText;
-
- ««« BEGIN: PapyrusGenCode
- ««« Add attributes to manage extended editors
- «generatedMemberComment('direct edition mode (default, undefined, registered editor, etc.)')»
- protected int directEditionMode = org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.UNDEFINED_DIRECT_EDITOR;
-
- «generatedMemberComment('configuration from a registered edit dialog')»
- protected org.eclipse.papyrus.extensionpoints.editors.configuration.IDirectEditorConfiguration configuration;
- ««« END: BEGIN: PapyrusGenCode
-
-'''
- override methods(GenCommonBase it, boolean needsRefreshBounds, boolean readOnly, boolean useElementIcon, Viewmap viewmap,
- LabelModelFacet modelFacet, GenCommonBase host, GenDiagram diagram) '''
-
- «getLabelTextHelper(it)»
-
- «setLabelTextHelper(it)»
-
- «getLabelIconHelper(it)»
-
- «setLabelIconHelper(it)»
-
- « labelSetter(it)»
-
- « getModelChildren(it)»
-
- « getChildBySemanticHint(it)»
-««« ITEMIS CHANGES
- « setParser (it)»
-««« ITEMIS CHANGES END
- « getParserElement(it,modelFacet)»
-
- « getLabelIcon(it,useElementIcon, diagram)»
-
- « getLabelText(it)»
-
- « setLabelText(it,diagram)»
-
- « getEditText(it)»
-
- « isEditable(it,readOnly)»
-
- « getEditTextValidator(it)»
-
- « getCompletionProcessor(it)»
-
- « getParserOptions(it)»
-
- « getParser(it,modelFacet, diagram, host)»
-
- « getManager(it,diagram)»
-
- « setManager(it)»
-
- « performDirectEdit(it)»
-
- « performDirectEditAtPoint(it)»
-
- « performDirectEditWithInitialChar(it)»
-
- « performDirectEditRequest(it,diagram)»
-
- « initializeDirectEditManager(it)»
-
- « refreshVisuals(it,needsRefreshBounds)»
-
- « refreshLabel(it,diagram)»
-
- « refreshUnderline(it)»
-
- « refreshStrikeThrough(it)»
-
- « refreshFont(it)»
-
- « setFontColor(it)»
-
- « addSemanticListeners(it)»
-
- « removeSemanticListeners(it)»
-
- « getAccessibleEditPart(it)»
-
- « getFontStyleOwnerView(it,viewmap)»
-
- ««« BEGIN: PapyrusGenCode
- ««« Add extended editors management for direct edit
- « getDirectEditionType(it,readOnly)»
-
- « checkExtendedEditor(it)»
-
- « checkDefaultEdition(it)»
-
- « initExtendedEditorConfiguration(it)»
-
- « updateExtendedEditorConfiguration(it)»
-
- « performDefaultDirectEditorEdit(it)»
-
- «««END: PapyrusGenCode
-'''
-
-def labelSetterName(ParentAssignedViewmap it) '''
-«IF setterName != null»«setterName»«ELSE»setLabel«ENDIF»
-'''
-
-override labelSetterName(Viewmap it)'''setLabel'''
-
-override getLabelTextHelper (GenCommonBase it)'''
- « generatedMemberComment»
- protected String getLabelTextHelper(org.eclipse.draw2d.IFigure figure) {
- if (figure instanceof org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) {
- return ((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) figure).getText();
- } else if (figure instanceof org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) {
- return ((org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) figure).getText();
- } else {
- return ((org.eclipse.draw2d.Label) figure).getText();
- }
- }
-'''
-
-override setLabelTextHelper (GenCommonBase it)'''
- «generatedMemberComment»
- protected void setLabelTextHelper(org.eclipse.draw2d.IFigure figure, String text) {
- if (figure instanceof org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) {
- ((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) figure).setText(text);
- } else if (figure instanceof org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) {
- ((org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) figure).setText(text);
- } else {
- ((org.eclipse.draw2d.Label) figure).setText(text);
- }
- }
-'''
-
-override getLabelIconHelper (GenCommonBase it)'''
- «generatedMemberComment»
- protected org.eclipse.swt.graphics.Image getLabelIconHelper(org.eclipse.draw2d.IFigure figure) {
- if (figure instanceof org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) {
- return ((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) figure).getIcon();
- } else if (figure instanceof org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) {
- return ((org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) figure).getIcon();
- } else {
- return ((org.eclipse.draw2d.Label) figure).getIcon();
- }
- }
-'''
-
-override setLabelIconHelper (GenCommonBase it)'''
- «generatedMemberComment»
- protected void setLabelIconHelper(org.eclipse.draw2d.IFigure figure, org.eclipse.swt.graphics.Image icon) {
- if (figure instanceof org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) {
- ((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) figure).setIcon(icon);
- } else if (figure instanceof org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) {
- ((org.eclipse.papyrus.uml.diagram.common.figure.node.ILabelFigure) figure).setIcon(icon);
- } else {
- ((org.eclipse.draw2d.Label) figure).setIcon(icon);
- }
- }
-'''
-
-override labelSetter (GenCommonBase it)'''
- «generatedMemberComment»
- public void « labelSetterName (viewmap)»(« labelSetterFigureClassName(viewmap)» figure) {
- unregisterVisuals();
- setFigure(figure);
- defaultText = getLabelTextHelper(figure);
- registerVisuals();
- refreshVisuals();
- }
-'''
-
-def labelSetterFigureClassName (ParentAssignedViewmap it)'''
- «IF figureQualifiedClassName != null»
- «figureQualifiedClassName»
- «ELSE»
- org.eclipse.draw2d.IFigure
- «ENDIF»
-'''
-
-override labelSetterFigureClassName (Viewmap it)'''
- org.eclipse.draw2d.IFigure
-'''
-
-override getModelChildren (GenCommonBase it)'''
- «generatedMemberComment»
- protected java.util.List<?> getModelChildren() {
- return java.util.Collections.EMPTY_LIST;
- }
-'''
-
-override getChildBySemanticHint (GenCommonBase it)'''
- «generatedMemberComment»
- public org.eclipse.gmf.runtime.diagram.ui.editparts.IGraphicalEditPart getChildBySemanticHint(String semanticHint) {
- return null;
- }
-'''
-
-def setParser (GenCommonBase it)'''
- «generatedMemberComment»
- public void setParser(org.eclipse.gmf.runtime.common.ui.services.parser.IParser parser) {
- this.parser = parser;
- }
-'''
-
-override getParserElement(GenCommonBase it, LabelModelFacet modelFacet) '''
- «generatedMemberComment»
- protected org.eclipse.emf.ecore.EObject getParserElement() {
- «IF modelFacet == null»
- org.eclipse.emf.ecore.EObject element = resolveSemanticElement();
- return element != null ? element : (org.eclipse.gmf.runtime.notation.View) getModel();
- «ELSE»« getParserElement(modelFacet)»«ENDIF»
- }
-'''
-
-def getParserElement (LabelModelFacet it)'''
- return resolveSemanticElement();
-'''
-
-def getParserElement (DesignLabelModelFacet it)'''
- return (org.eclipse.gmf.runtime.notation.View) getModel();
-'''
-
-override getLabelIcon(GenCommonBase it,boolean useElementIcon, GenDiagram diagram ) '''
- «generatedMemberComment»
- protected org.eclipse.swt.graphics.Image getLabelIcon() {
- «IF useElementIcon»
- ««« START: PapyrusGenCode
- return org.eclipse.papyrus.infra.gmfdiag.common.utils.DiagramEditPartsUtil.getIcon(getParserElement(), getViewer());
- ««« END: PapyrusGenCode
- «ELSE»
- return null;
- «ENDIF»
- }
-'''
-
-override getLabelText (GenCommonBase it)'''
- «generatedMemberComment»
- protected String getLabelText() {
- String text = null;
- org.eclipse.emf.ecore.EObject parserElement = getParserElement();
- if (parserElement != null && getParser() != null) {
- text = getParser().getPrintString(
- org.eclipse.papyrus.infra.gmfdiag.common.parsers.ParserUtil.getParserAdapter(getParserElement(), this),
- getParserOptions().intValue());
- }
- if (text == null || text.length() == 0) {
- text = defaultText;
- }
- return text;
- }
-'''
-
-override setLabelText(GenCommonBase it, GenDiagram diagram) '''
- «generatedMemberComment»
- public void setLabelText(String text) {
- setLabelTextHelper(getFigure(), text);
- Object pdEditPolicy = getEditPolicy(org.eclipse.gef.EditPolicy.PRIMARY_DRAG_ROLE);
- if (pdEditPolicy instanceof «diagram.getTextSelectionEditPolicyQualifiedClassName()») {
- ((«diagram.getTextSelectionEditPolicyQualifiedClassName()») pdEditPolicy).refreshFeedback();
- }
- Object sfEditPolicy = getEditPolicy(org.eclipse.gef.EditPolicy.SELECTION_FEEDBACK_ROLE);
- if (sfEditPolicy instanceof «diagram.getTextSelectionEditPolicyQualifiedClassName()») {
- ((«diagram.getTextSelectionEditPolicyQualifiedClassName()») sfEditPolicy).refreshFeedback();
- }
- }
-'''
-
-override getEditText (GenCommonBase it)'''
- «generatedMemberComment»
- public String getEditText() {
- if (getParserElement() == null || getParser() == null) {
- return ""; «nonNLS»
- }
- return getParser().getEditString(
- org.eclipse.papyrus.infra.gmfdiag.common.parsers.ParserUtil.getParserAdapter(getParserElement(), this),
- getParserOptions().intValue());
- }
-'''
-
-def isEditable(GenCommonBase it, boolean readOnly ) '''
- «generatedMemberComment»
- protected boolean isEditable() {
- «IF readOnly»
- return false;
- «ELSE»
- return getParser() != null;
- «ENDIF»
- }
-'''
-
-override getEditTextValidator (GenCommonBase it)'''
- «generatedMemberComment»
- public org.eclipse.jface.viewers.ICellEditorValidator getEditTextValidator() {
- return new org.eclipse.jface.viewers.ICellEditorValidator() {
-
- «overrideI»
- public String isValid(final Object value) {
- if (value instanceof String) {
- final org.eclipse.emf.ecore.EObject element = getParserElement();
- final org.eclipse.gmf.runtime.common.ui.services.parser.IParser parser = getParser();
- try {
- org.eclipse.gmf.runtime.common.ui.services.parser.IParserEditStatus valid =
- (org.eclipse.gmf.runtime.common.ui.services.parser.IParserEditStatus) getEditingDomain().runExclusive(
- new org.eclipse.emf.transaction.RunnableWithResult.Impl<java.lang.Object>() {
-
- «overrideI»
- public void run() {
- setResult(parser.isValidEditString(org.eclipse.papyrus.infra.gmfdiag.common.parsers.ParserUtil.getParserAdapter(getParserElement(), «editPartClassName».this), (String) value));
- }
- });
- return valid.getCode() == org.eclipse.gmf.runtime.common.ui.services.parser.IParserEditStatus.EDITABLE ? null : valid.getMessage();
- } catch (InterruptedException ie) {
- ie.printStackTrace();
- }
- }
-
- // shouldn't get here
- return null;
- }
- };
- }
-'''
-
-override getCompletionProcessor (GenCommonBase it)'''
- «generatedMemberComment»
- public org.eclipse.jface.text.contentassist.IContentAssistProcessor getCompletionProcessor() {
- if (getParserElement() == null || getParser() == null) {
- return null;
- }
- return getParser().getCompletionProcessor(org.eclipse.papyrus.infra.gmfdiag.common.parsers.ParserUtil.getParserAdapter(getParserElement(), this));
- }
-'''
-
-override getParserOptions (GenCommonBase it)'''
- «generatedMemberComment»
- public org.eclipse.gmf.runtime.common.ui.services.parser.ParserOptions getParserOptions() {
- return org.eclipse.gmf.runtime.common.ui.services.parser.ParserOptions.NONE;
- }
-'''
-
-override getParser(GenCommonBase it, LabelModelFacet modelFacet, GenDiagram diagram , GenCommonBase host ) '''
- «generatedMemberComment»
- public org.eclipse.gmf.runtime.common.ui.services.parser.IParser getParser() {
- if (parser == null) {
- parser = org.eclipse.papyrus.infra.gmfdiag.common.parsers.ParserUtil.getParser(«xptElementTypes.accessElementType(host)», getParserElement(), this, VISUAL_ID);
- }
- return parser;
- }
-'''
-
-def getManager(GenCommonBase it,GenDiagram diagram) '''
- «generatedMemberComment»
- protected org.eclipse.gef.tools.DirectEditManager getManager() {
- if (manager == null) {
- setManager(new org.eclipse.papyrus.uml.diagram.common.directedit.MultilineLabelDirectEditManager(this,
- org.eclipse.papyrus.uml.diagram.common.directedit.MultilineLabelDirectEditManager.getTextCellEditorClass(this),
- «diagram.getEditPartFactoryQualifiedClassName()».getTextCellEditorLocator(this)));
- }
- return manager;
- }
-'''
-
-override setManager (GenCommonBase it)'''
- «generatedMemberComment»
- protected void setManager(org.eclipse.gef.tools.DirectEditManager manager) {
- this.manager = manager;
- }
-'''
-
-override performDirectEdit (GenCommonBase it)'''
- «generatedMemberComment»
- protected void performDirectEdit() {
- org.eclipse.swt.custom.BusyIndicator.showWhile(org.eclipse.swt.widgets.Display.getDefault(), new java.lang.Runnable() {
-
- «overrideI»
- public void run() {
- getManager().show();
- }
- });
- }
-'''
-
-def performDirectEditAtPoint (GenCommonBase it)'''
- «generatedMemberComment»
- protected void performDirectEdit(org.eclipse.draw2d.geometry.Point eventLocation) {
- if (getManager() instanceof org.eclipse.gmf.runtime.diagram.ui.tools.TextDirectEditManager) {
- ((org.eclipse.gmf.runtime.diagram.ui.tools.TextDirectEditManager) getManager()).show(eventLocation.getSWTPoint());
- }
- }
-'''
-
-override performDirectEditWithInitialChar (GenCommonBase it)'''
- «generatedMemberComment»
- protected void performDirectEdit(char initialCharacter) {
- if (getManager() instanceof org.eclipse.gmf.runtime.diagram.ui.tools.TextDirectEditManager) {
- ((org.eclipse.gmf.runtime.diagram.ui.tools.TextDirectEditManager) getManager()).show(initialCharacter);
- } else {
- performDirectEdit();
- }
- }
-'''
-
-def performDirectEditRequest(GenCommonBase it, GenDiagram diagram ) '''
- «generatedMemberComment»
- protected void performDirectEditRequest(org.eclipse.gef.Request request) {
-
- final org.eclipse.gef.Request theRequest = request;
-
- if (org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.UNDEFINED_DIRECT_EDITOR == directEditionMode) {
- directEditionMode = getDirectEditionType();
- }
- switch (directEditionMode) {
- case org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.NO_DIRECT_EDITION:
- // no direct edition mode => does nothing
- return;
- case org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.EXTENDED_DIRECT_EDITOR:
- updateExtendedEditorConfiguration();
- if (configuration == null || configuration.getLanguage() == null) {
- // Create default edit manager
- setManager(new org.eclipse.papyrus.uml.diagram.common.directedit.MultilineLabelDirectEditManager(this,
- org.eclipse.papyrus.uml.diagram.common.directedit.MultilineLabelDirectEditManager.getTextCellEditorClass(this),
- «diagram.getEditPartFactoryQualifiedClassName()».getTextCellEditorLocator(this)));
- performDefaultDirectEditorEdit(theRequest);
- } else {
- configuration.preEditAction(resolveSemanticElement());
- org.eclipse.jface.dialogs.Dialog dialog = null;
- if (configuration instanceof org.eclipse.papyrus.extensionpoints.editors.configuration.ICustomDirectEditorConfiguration) {
- setManager(((org.eclipse.papyrus.extensionpoints.editors.configuration.ICustomDirectEditorConfiguration) configuration).createDirectEditManager(this));
- initializeDirectEditManager(theRequest);
- return;
- } else if (configuration instanceof org.eclipse.papyrus.extensionpoints.editors.configuration.IPopupEditorConfiguration) {
- org.eclipse.papyrus.extensionpoints.editors.ui.IPopupEditorHelper helper = ((org.eclipse.papyrus.extensionpoints.editors.configuration.IPopupEditorConfiguration)configuration).createPopupEditorHelper(this) ;
- helper.showEditor() ;
- return ;
- }
- else if(configuration instanceof org.eclipse.papyrus.extensionpoints.editors.configuration.IAdvancedEditorConfiguration) {
- dialog = ((org.eclipse.papyrus.extensionpoints.editors.configuration.IAdvancedEditorConfiguration)configuration).createDialog(org.eclipse.ui.PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), resolveSemanticElement(), configuration.getTextToEdit(resolveSemanticElement()));
- } else if(configuration instanceof org.eclipse.papyrus.extensionpoints.editors.configuration.IDirectEditorConfiguration) {
- dialog = new org.eclipse.papyrus.extensionpoints.editors.ui.ExtendedDirectEditionDialog(org.eclipse.ui.PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), resolveSemanticElement(), configuration.getTextToEdit(resolveSemanticElement()), configuration);
- } else {
- return;
- }
- final org.eclipse.jface.dialogs.Dialog finalDialog = dialog;
-
- if (org.eclipse.jface.window.Window.OK == dialog.open()) {
- org.eclipse.emf.transaction.TransactionalEditingDomain domain = getEditingDomain();
- org.eclipse.emf.transaction.RecordingCommand command = new org.eclipse.emf.transaction.RecordingCommand(domain, "Edit Label") {
-
- @Override
- protected void doExecute() {
- configuration.postEditAction(resolveSemanticElement(), ((org.eclipse.papyrus.extensionpoints.editors.ui.ILabelEditorDialog)finalDialog).getValue());
-
- }
- };
- domain.getCommandStack().execute(command);
- }
- }
- break;
- case org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.DEFAULT_DIRECT_EDITOR:
- initializeDirectEditManager(theRequest);
- break;
- default:
- break;
- }
- }
-'''
-
-def initializeDirectEditManager (GenCommonBase it)'''
- «generatedMemberComment»
- protected void initializeDirectEditManager(final org.eclipse.gef.Request request) {
- // initialize the direct edit manager
- try {
- getEditingDomain().runExclusive(new Runnable() {
- «overrideI»
- public void run() {
- if (isActive() && isEditable()) {
- if (request.getExtendedData().get(
- org.eclipse.gmf.runtime.diagram.ui.requests.RequestConstants.REQ_DIRECTEDIT_EXTENDEDDATA_INITIAL_CHAR) instanceof Character) {
- Character initialChar = (Character) request.getExtendedData().get(org.eclipse.gmf.runtime.diagram.ui.requests.RequestConstants.REQ_DIRECTEDIT_EXTENDEDDATA_INITIAL_CHAR);
- performDirectEdit(initialChar.charValue());
- }
- else {
- performDirectEdit();
- }
- }
- }
- });
- } catch (InterruptedException e) {
- e.printStackTrace();
- }
- }
-'''
-
-def refreshVisuals(GenCommonBase it, boolean needsRefreshBounds ) '''
- «generatedMemberComment»
- protected void refreshVisuals() {
- super.refreshVisuals();
- refreshLabel();
- refreshFont();
- refreshFontColor();
- refreshUnderline();
- refreshStrikeThrough();
- «IF needsRefreshBounds»
- refreshBounds();
- «ENDIF»
- }
-'''
-
-override refreshLabel(GenCommonBase it , GenDiagram diagram )'''
- «generatedMemberComment»
- protected void refreshLabel() {
- org.eclipse.gef.EditPolicy maskLabelPolicy = getEditPolicy(org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.IMaskManagedLabelEditPolicy.MASK_MANAGED_LABEL_EDIT_POLICY);
- if(maskLabelPolicy==null){
- maskLabelPolicy = getEditPolicy(org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.IndirectMaskLabelEditPolicy.INDRIRECT_MASK_MANAGED_LABEL);
- }
- if (maskLabelPolicy == null) {
- org.eclipse.gmf.runtime.notation.View view = (org.eclipse.gmf.runtime.notation.View)getModel();
- if(view.isVisible()) {
- setLabelTextHelper(getFigure(), getLabelText());
- setLabelIconHelper(getFigure(), getLabelIcon());
- }
- else {
- setLabelTextHelper(getFigure(), ""); //$NON-NLS-1$
- setLabelIconHelper(getFigure(), null);
- }
- }
- Object pdEditPolicy = getEditPolicy(org.eclipse.gef.EditPolicy.PRIMARY_DRAG_ROLE);
- if (pdEditPolicy instanceof «diagram.getTextSelectionEditPolicyQualifiedClassName()») {
- ((«diagram.getTextSelectionEditPolicyQualifiedClassName()») pdEditPolicy).refreshFeedback();
- }
- Object sfEditPolicy = getEditPolicy(org.eclipse.gef.EditPolicy.SELECTION_FEEDBACK_ROLE);
- if (sfEditPolicy instanceof «diagram.getTextSelectionEditPolicyQualifiedClassName()») {
- ((«diagram.getTextSelectionEditPolicyQualifiedClassName()») sfEditPolicy).refreshFeedback();
- }
- }
-'''
-
-override refreshUnderline (GenCommonBase it)'''
- «generatedMemberComment»
- protected void refreshUnderline() {
- org.eclipse.gmf.runtime.notation.FontStyle style =
- (org.eclipse.gmf.runtime.notation.FontStyle) getFontStyleOwnerView().getStyle(
- org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getFontStyle());
- if (style != null && getFigure() instanceof org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) {
- ((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) getFigure()).setTextUnderline(style.isUnderline());
- }
- if(resolveSemanticElement() instanceof org.eclipse.uml2.uml.Feature){
- if(((org.eclipse.uml2.uml.Feature)resolveSemanticElement()).isStatic()){
- ((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel)getFigure()).setTextUnderline(true);
- }
- else{((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel)getFigure()).setTextUnderline(false);}
- }
- }
-'''
-
-override refreshStrikeThrough (GenCommonBase it)'''
- «generatedMemberComment»
- protected void refreshStrikeThrough() {
- org.eclipse.gmf.runtime.notation.FontStyle style =
- (org.eclipse.gmf.runtime.notation.FontStyle) getFontStyleOwnerView().getStyle(
- org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getFontStyle());
- if (style != null && getFigure() instanceof org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) {
- ((org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel) getFigure()).setTextStrikeThrough(style.isStrikeThrough());
- }
- }
-'''
-
-override refreshFont (GenCommonBase it)'''
- «generatedMemberComment»
- protected void refreshFont() {
- org.eclipse.gmf.runtime.notation.FontStyle style =
- (org.eclipse.gmf.runtime.notation.FontStyle) getFontStyleOwnerView().getStyle(
- org.eclipse.gmf.runtime.notation.NotationPackage.eINSTANCE.getFontStyle());
- if (style != null) {
- org.eclipse.swt.graphics.FontData fontData = new org.eclipse.swt.graphics.FontData(
- style.getFontName(), style.getFontHeight(),
- (style.isBold() ? org.eclipse.swt.SWT.BOLD : org.eclipse.swt.SWT.NORMAL) |
- (style.isItalic() ? org.eclipse.swt.SWT.ITALIC : org.eclipse.swt.SWT.NORMAL));
- setFont(fontData);
- }
- }
-'''
-
-override setFontColor (GenCommonBase it)'''
- «generatedMemberComment»
- protected void setFontColor(org.eclipse.swt.graphics.Color color) {
- getFigure().setForegroundColor(color);
- }
-'''
-
-override addSemanticListeners (GenCommonBase it)'''
- «generatedMemberComment»
- protected void addSemanticListeners() {
- if (getParser() instanceof org.eclipse.gmf.runtime.emf.ui.services.parser.ISemanticParser) {
- org.eclipse.emf.ecore.EObject element = resolveSemanticElement();
- parserElements = ((org.eclipse.gmf.runtime.emf.ui.services.parser.ISemanticParser) getParser()).getSemanticElementsBeingParsed(element);
- for (int i = 0; i < parserElements.size(); i++) {
- addListenerFilter("SemanticModel" + i, this, (org.eclipse.emf.ecore.EObject) parserElements.get(i)); «nonNLS»
- }
- } else {
- super.addSemanticListeners();
- }
- }
-'''
-
-override removeSemanticListeners (GenCommonBase it)'''
- «generatedMemberComment»
- protected void removeSemanticListeners() {
- if (parserElements != null) {
- for (int i = 0; i < parserElements.size(); i++) {
- removeListenerFilter("SemanticModel" + i); «nonNLS»
- }
- } else {
- super.removeSemanticListeners();
- }
- }
-'''
-
-override getAccessibleEditPart (GenCommonBase it)'''
- «generatedMemberComment»
- protected org.eclipse.gef.AccessibleEditPart getAccessibleEditPart() {
- if (accessibleEP == null) {
- accessibleEP = new AccessibleGraphicalEditPart() {
-
- «overrideC»
- public void getName(org.eclipse.swt.accessibility.AccessibleEvent e) {
- e.result = getLabelTextHelper(getFigure());
- }
- };
- }
- return accessibleEP;
- }
-'''
-
-override getFontStyleOwnerView(GenCommonBase it, Viewmap viewmap ) '''
- «generatedMemberComment»
- private org.eclipse.gmf.runtime.notation.View getFontStyleOwnerView() {
- «IF isFixedFont(viewmap)»
- return (org.eclipse.gmf.runtime.notation.View) getModel();
- «ELSE»
- return getPrimaryView();
- «ENDIF»
- }
-'''
-
-
-//BEGIN: PapyrusGenCode
-//Methods for advanced direct edition
-
-def getDirectEditionType(GenCommonBase it, Boolean readOnly) '''
- /**
- * Returns the kind of associated editor for direct edition.
- *
- * @return an <code>int</code> corresponding to the kind of direct editor, @see org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition
- * @generated
- */
- public int getDirectEditionType() {
- «IF readOnly»
- // The label is read-only (defined in GMFGen model)
- return org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.NO_DIRECT_EDITION;
- «ELSE»
- if (checkExtendedEditor()) {
- initExtendedEditorConfiguration();
- return org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.EXTENDED_DIRECT_EDITOR;
- }
- if (checkDefaultEdition()) {
- return org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.DEFAULT_DIRECT_EDITOR;
- }
-
- // not a named element. no specific editor => do nothing
- return org.eclipse.papyrus.uml.diagram.common.editpolicies.IDirectEdition.NO_DIRECT_EDITION;
- «ENDIF»
- }
-'''
-
-def checkExtendedEditor (GenCommonBase it)'''
- /**
- * Checks if an extended editor is present.
- *
- * @return <code>true</code> if an extended editor is present.
- * @generated
- */
- protected boolean checkExtendedEditor() {
- if (resolveSemanticElement() != null) {
- return org.eclipse.papyrus.extensionpoints.editors.utils.DirectEditorsUtil.hasSpecificEditorConfiguration(resolveSemanticElement(),this);
- }
- return false;
- }
-'''
-
-def checkDefaultEdition (GenCommonBase it)'''
- /**
- * Checks if a default direct edition is available
- *
- * @return <code>true</code> if a default direct edition is available
- * @generated
- */
- protected boolean checkDefaultEdition() {
- return (getParser() != null);
- }
-'''
-
-def initExtendedEditorConfiguration (GenCommonBase it)'''
- /**
- * Initializes the extended editor configuration
- * @generated
- */
- protected void initExtendedEditorConfiguration() {
- if (configuration == null) {
- final String languagePreferred = org.eclipse.papyrus.extensionpoints.editors.Activator.getDefault().getPreferenceStore().getString(org.eclipse.papyrus.extensionpoints.editors.utils.IDirectEditorsIds.EDITOR_FOR_ELEMENT + resolveSemanticElement().eClass().getInstanceClassName());
- if (languagePreferred != null && !languagePreferred.equals("")) {
- configuration = org.eclipse.papyrus.extensionpoints.editors.utils.DirectEditorsUtil.findEditorConfiguration(languagePreferred, resolveSemanticElement(), this);
- } else {
- configuration = org.eclipse.papyrus.extensionpoints.editors.utils.DirectEditorsUtil.findEditorConfiguration(org.eclipse.papyrus.extensionpoints.editors.utils.IDirectEditorsIds.UML_LANGUAGE, resolveSemanticElement(), this);
- }
- }
- }
-'''
-
-def updateExtendedEditorConfiguration (GenCommonBase it)'''
- /**
- * Updates the preference configuration
- * @generated
- */
- protected void updateExtendedEditorConfiguration() {
- String languagePreferred = org.eclipse.papyrus.extensionpoints.editors.Activator.getDefault().getPreferenceStore().getString(
- org.eclipse.papyrus.extensionpoints.editors.utils.IDirectEditorsIds.EDITOR_FOR_ELEMENT + resolveSemanticElement().eClass().getInstanceClassName());
- if (languagePreferred != null && !languagePreferred.equals("") && !languagePreferred.equals(configuration.getLanguage())) {
- configuration = org.eclipse.papyrus.extensionpoints.editors.utils.DirectEditorsUtil.findEditorConfiguration(languagePreferred, resolveSemanticElement(),this);
- } else if (org.eclipse.papyrus.extensionpoints.editors.utils.IDirectEditorsIds.SIMPLE_DIRECT_EDITOR.equals(languagePreferred)) {
- configuration = null;
- }
- }
-'''
-
-def performDefaultDirectEditorEdit (GenCommonBase it)'''
- /**
- * Performs the direct edit usually used by GMF editors.
- * @param theRequest the direct edit request that starts the direct edit system
- * @generated
- */
- protected void performDefaultDirectEditorEdit(final org.eclipse.gef.Request theRequest) {
- // initialize the direct edit manager
- try {
- getEditingDomain().runExclusive(new Runnable() {
-
- «overrideI»
- public void run() {
- if (isActive() && isEditable()) {
- if (theRequest.getExtendedData().get(org.eclipse.gmf.runtime.diagram.ui.requests.RequestConstants.REQ_DIRECTEDIT_EXTENDEDDATA_INITIAL_CHAR) instanceof Character) {
- Character initialChar = (Character) theRequest.getExtendedData().get(
- org.eclipse.gmf.runtime.diagram.ui.requests.RequestConstants.REQ_DIRECTEDIT_EXTENDEDDATA_INITIAL_CHAR);
- performDirectEdit(initialChar.charValue());
- } else if ((theRequest instanceof org.eclipse.gef.requests.DirectEditRequest) && (getEditText().equals(getLabelText()))) {
- org.eclipse.gef.requests.DirectEditRequest editRequest = (org.eclipse.gef.requests.DirectEditRequest) theRequest;
- performDirectEdit(editRequest.getLocation());
- } else {
- performDirectEdit();
- }
- }
- }
- });
- } catch (InterruptedException e) {
- e.printStackTrace();
- }
- }
-'''
-//END: PapyrusGenCode
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/update/CanonicalUpdate.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/update/CanonicalUpdate.xtend
deleted file mode 100644
index 6e4fe0a5516..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/diagram/update/CanonicalUpdate.xtend
+++ /dev/null
@@ -1,163 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Artem Tikhomirov - refactoring of containerBaseCanonicalMethods.xpt; extraction of API/non-API of CEP templates
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.diagram.update
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.gmf.codegen.gmfgen.GenContainerBase
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Common
-import xpt.diagram.updater.DiagramUpdater
-import xpt.diagram.updater.NodeDescriptor
-import xpt.diagram.updater.Utils_qvto
-import xpt.diagram.updater.LinkDescriptor
-import xpt.editor.VisualIDRegistry
-
-@Singleton class CanonicalUpdate extends impl.diagram.update.CanonicalUpdate {
- @Inject extension Common;
- @Inject extension Utils_qvto;
-
- @Inject NodeDescriptor nodeDescriptor;
- @Inject MetaModel xptMetaModel;
- @Inject DiagramUpdater xptDiagramUpdater;
- @Inject LinkDescriptor linkDescriptor;
- @Inject VisualIDRegistry xptVisualIDRegistry;
-
- override def getFeaturesToSynchronizeMethod(GenContainerBase it) '''
- «IF getSemanticChildrenChildFeatures(it).size == 1»
-
- «generatedMemberComment»
- protected org.eclipse.emf.ecore.EStructuralFeature getFeatureToSynchronize() {
- return «xptMetaModel.MetaFeature(getSemanticChildrenContainmentFeatures(it).head)»;
- }
- «ELSEIF getSemanticChildrenChildFeatures(it).size > 1»
-
- «generatedMemberComment»
- protected java.util.Set<org.eclipse.emf.ecore.EStructuralFeature> getFeaturesToSynchronize() {
- if (myFeaturesToSynchronize == null) {
- myFeaturesToSynchronize = new java.util.HashSet<org.eclipse.emf.ecore.EStructuralFeature>();
- «FOR f : getSemanticChildrenContainmentFeatures(it)»
- «addContainmentFeature(f)»
- «ENDFOR»
- }
- return myFeaturesToSynchronize;
- }
- «ENDIF»
- '''
-
- override def getSemanticChildrenListMethod(GenContainerBase it) '''
- «generatedMemberComment»
- protected java.util.List<org.eclipse.emf.ecore.EObject> getSemanticChildrenList() {
- «IF hasSemanticChildren(it)/*REVISIT: is there real need for this check - Generator seems to consult needsCanonicalEP, which in turns ensures there are semantic children?*/»
- org.eclipse.gmf.runtime.notation.View viewObject = (org.eclipse.gmf.runtime.notation.View) getHost().getModel();
- java.util.LinkedList<org.eclipse.emf.ecore.EObject> result = new java.util.LinkedList<org.eclipse.emf.ecore.EObject>();
- java.util.List<«nodeDescriptor.qualifiedClassName(it.diagram.editorGen.diagramUpdater)»> childDescriptors = «xptDiagramUpdater.
- getSemanticChildrenMethodCall(it)»(viewObject);
- for («nodeDescriptor.qualifiedClassName(it.diagram.editorGen.diagramUpdater)» d : childDescriptors) {
- result.add(d.getModelElement());
- }
- return result;
- «ELSE»
- return java.util.Collections.EMPTY_LIST;
- «ENDIF»
- }
- '''
-
- override def refreshConnectionsBody(GenDiagram it) '''
- «Domain2Notation(it)» domain2NotationMap = new «Domain2Notation(it)»();
- java.util.Collection<«linkDescriptor.qualifiedClassName(editorGen.diagramUpdater)»> linkDescriptors = collectAllLinks(getDiagram(), domain2NotationMap);
- java.util.List<org.eclipse.gmf.runtime.notation.View> edges = new java.util.ArrayList<org.eclipse.gmf.runtime.notation.View>();
- for (Object edge : getDiagram().getEdges())
- {
- if (edge instanceof org.eclipse.gmf.runtime.notation.View)
- {
- edges.add((org.eclipse.gmf.runtime.notation.View) edge);
- }
- }
- java.util.Collection<org.eclipse.gmf.runtime.notation.View> existingLinks = new java.util.LinkedList<org.eclipse.gmf.runtime.notation.View>(edges);
- for (java.util.Iterator<org.eclipse.gmf.runtime.notation.View> linksIterator = existingLinks.iterator(); linksIterator.hasNext();) {
- org.eclipse.gmf.runtime.notation.Edge nextDiagramLink = (org.eclipse.gmf.runtime.notation.Edge) linksIterator.next();
- int diagramLinkVisualID = «xptVisualIDRegistry.getVisualIDMethodCall(it)»(nextDiagramLink);
- if (diagramLinkVisualID == -1«FOR link : links.filter[gl|gl.modelFacet == null]»«compareLinkVisualID(link)»«ENDFOR») {
- if (nextDiagramLink.getSource() != null && nextDiagramLink.getTarget() != null) {
- linksIterator.remove();
- }
- continue;
- }
- org.eclipse.emf.ecore.EObject diagramLinkObject = nextDiagramLink.getElement();
- org.eclipse.emf.ecore.EObject diagramLinkSrc = nextDiagramLink.getSource().getElement();
- org.eclipse.emf.ecore.EObject diagramLinkDst = nextDiagramLink.getTarget().getElement();
- for (java.util.Iterator<«it.editorGen.diagramUpdater.linkDescriptorQualifiedClassName»> linkDescriptorsIterator = linkDescriptors.iterator(); linkDescriptorsIterator.hasNext();) {
- «linkDescriptor.qualifiedClassName(it.editorGen.diagramUpdater)» nextLinkDescriptor = linkDescriptorsIterator.next();
- if (diagramLinkObject == nextLinkDescriptor.getModelElement() && diagramLinkSrc == nextLinkDescriptor.getSource() && diagramLinkDst == nextLinkDescriptor.getDestination() && diagramLinkVisualID == nextLinkDescriptor.getVisualID()) {
- linksIterator.remove();
- linkDescriptorsIterator.remove();
- break;
- }
- }
- }
- deleteViews(existingLinks.iterator());
- return createConnections(linkDescriptors, domain2NotationMap);
- '''
-
- override def collectAllLinksMethod(GenDiagram it) '''
- «generatedMemberComment»
- private java.util.Collection<«linkDescriptor.qualifiedClassName(it.editorGen.diagramUpdater)»> collectAllLinks(org.eclipse.gmf.runtime.notation.View view, «Domain2Notation(
- it)» domain2NotationMap) {
- if (!«VisualIDRegistry::modelID(it)».equals(«xptVisualIDRegistry.getModelIDMethodCall(it)»(view))) {
- return java.util.Collections.emptyList();
- }
- java.util.LinkedList<«linkDescriptor.qualifiedClassName(it.editorGen.diagramUpdater)»> result = new java.util.LinkedList<«linkDescriptor.
- qualifiedClassName(it.editorGen.diagramUpdater)»>();
- String vid = «xptVisualIDRegistry.getVisualIDMethodCall(it)»(view);
- if (vid != null) {
- switch (vid) {
- «FOR se : it.allSemanticElements»
- «caseSemanticElement(se)»
- «ENDFOR»
- }
- }
- for (java.util.Iterator<?> children = view.getChildren().iterator(); children.hasNext();) {
- result.addAll(collectAllLinks((org.eclipse.gmf.runtime.notation.View) children.next(), domain2NotationMap));
- }
- for (java.util.Iterator<?> edges = view.getSourceEdges().iterator(); edges.hasNext();) {
- result.addAll(collectAllLinks((org.eclipse.gmf.runtime.notation.View) edges.next(), domain2NotationMap));
- }
- return result;
- }
- '''
-
- override getEditPartMethod(GenDiagram it) '''
- «generatedMemberComment»
- private org.eclipse.gef.EditPart getEditPart(org.eclipse.emf.ecore.EObject domainModelElement, «Domain2Notation(it)» domain2NotationMap) {
- org.eclipse.gmf.runtime.notation.View view = domain2NotationMap.get(domainModelElement);
- if (view != null) {
- return (org.eclipse.gef.EditPart) getHost().getViewer().getEditPartRegistry().get(view);
- }
- return null;
- }
- '''
-
- override getHintedEditPartMethod(GenDiagram it) '''
- «generatedMemberComment»
- protected final org.eclipse.gef.EditPart getHintedEditPart(org.eclipse.emf.ecore.EObject domainModelElement, «Domain2Notation(it)» domain2NotationMap, int hintVisualId) {
- org.eclipse.gmf.runtime.notation.View view = domain2NotationMap.getHinted(domainModelElement, «xptVisualIDRegistry.typeMethodCall(it, 'hintVisualId')»);
- if (view != null) {
- return (org.eclipse.gef.EditPart) getHost().getViewer().getEditPartRegistry().get(view);
- }
- return null;
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/parsers/ParserProvider.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/parsers/ParserProvider.xtend
deleted file mode 100644
index 7d21bab98fb..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/parsers/ParserProvider.xtend
+++ /dev/null
@@ -1,156 +0,0 @@
-/**
- * Copyright (c) 2007-2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Artem Tikhomirov (Borland) - [235113] alternative parser access
- * [244419] custom parsers
- * [138179] expression-backed labels
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.parsers
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import impl.parsers.expression_qvto
-import metamodel.MetaModel
-import org.eclipse.gmf.codegen.gmfgen.GenChildLabelNode
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import org.eclipse.gmf.codegen.gmfgen.GenParsers
-import parsers.ExpressionLabelParser
-import parsers.PredefinedParser
-import plugin.Activator
-import xpt.Common
-import xpt.Common_qvto
-import xpt.editor.VisualIDRegistry
-import xpt.expressions.OclTracker_qvto
-import xpt.expressions.getExpression
-import xpt.providers.ElementTypes
-import xpt.providers.ParserUtils_qvto
-
-@Singleton class ParserProvider extends impl.parsers.ParserProvider {
- @Inject extension Common
- @Inject extension Common_qvto
-
- @Inject extension OclTracker_qvto
- @Inject extension ParserUtils_qvto
- @Inject extension expression_qvto
-
- @Inject extension ExpressionLabelParser;
- @Inject extension PredefinedParser;
-
- @Inject getExpression xptGetExpression;
- @Inject MetaModel xptMetaModel;
- @Inject VisualIDRegistry xptVisualIDRegistry;
- @Inject ElementTypes xptElementTypes;
- @Inject parsers.ParserProvider xptParsers;
- @Inject Activator xptActivator;
-
- override def HintAdapterClass(GenParsers it) '''
- «generatedMemberComment()»
- private static class HintAdapter extends org.eclipse.gmf.runtime.emf.ui.services.parser.ParserHintAdapter {
-
- «generatedMemberComment()»
- private final org.eclipse.gmf.runtime.emf.type.core.IElementType elementType;
-
- «generatedMemberComment()»
- public HintAdapter(org.eclipse.gmf.runtime.emf.type.core.IElementType type,
- org.eclipse.emf.ecore.EObject object, String parserHint) {
- super(object, parserHint);
- «_assert('type != null')»
- elementType = type;
- }
-
- «generatedMemberComment()»
- public Object getAdapter(@SuppressWarnings("rawtypes") Class adapter) {
- if (org.eclipse.gmf.runtime.emf.type.core.IElementType.class.equals(adapter)) {
- return elementType;
- }
- return super.getAdapter(adapter);
- }
- }
- '''
-
- override dispatch dispatch_parsers(GenNode it) '''
- «FOR label : it.labels»
- «IF label.modelFacet != null»
- «dispatch_parser(label.modelFacet.parser, label.modelFacet, label)»
- «ENDIF»
- «ENDFOR»
- '''
-
- override dispatch dispatch_parsers(GenLink it) '''
- «FOR label : it.labels»
- «IF label.modelFacet != null»
- «dispatch_parser(label.modelFacet.parser, label.modelFacet, label)»
- «ENDIF»
- «ENDFOR»
- '''
-
- override dispatch dispatch_getParsers(GenNode it) //
- '''
- «FOR label : it.labels»
- «IF label.modelFacet != null»
- «doGetParser(label.modelFacet.parser, label)»
- «ENDIF»
- «ENDFOR»
-
- '''
-
- override dispatch dispatch_getParsers(GenLink it) //
- '''
- «FOR label : it.labels»
- «IF label.modelFacet != null»
- «doGetParser(label.modelFacet.parser, label)»
- «ENDIF»
- «ENDFOR»
-
- '''
-
- override dispatch dispatch_getParsers(GenChildLabelNode it) '''
- «IF it.modelFacet != null»
- «doGetParser(it.labelModelFacet.parser, it)»
- «ENDIF»
- '''
-
- override def getParserByVisualIdMethod(GenParsers it) '''
- «generatedMemberComment()»
- protected org.eclipse.gmf.runtime.common.ui.services.parser.IParser getParser(String visualID) {
- if (visualID != null) {
- switch (visualID) {
- «FOR node : editorGen.diagram.topLevelNodes»
- «dispatch_getParsers(node)»
- «ENDFOR»
- «FOR node : editorGen.diagram.childNodes»
- «dispatch_getParsers(node)»
- «ENDFOR»
- «FOR link : editorGen.diagram.links»
- «dispatch_getParsers(link)»
- «ENDFOR»
- }
- }
- return null;
- }
- '''
-
- override def provider_providesMethod(GenParsers it) '''
- «generatedMemberComment()»
- public boolean provides(org.eclipse.gmf.runtime.common.core.service.IOperation operation) {
- if (operation instanceof org.eclipse.gmf.runtime.common.ui.services.parser.GetParserOperation) {
- org.eclipse.core.runtime.IAdaptable hint =
- ((org.eclipse.gmf.runtime.common.ui.services.parser.GetParserOperation) operation).getHint();
- if («xptElementTypes.qualifiedClassName(editorGen.diagram)».getElement(hint) == null) {
- return false;
- }
- return getParser(hint) != null;
- }
- return false;
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/preferences/StandardPage.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/preferences/StandardPage.xtend
deleted file mode 100644
index f934212e028..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/impl/preferences/StandardPage.xtend
+++ /dev/null
@@ -1,58 +0,0 @@
-/**
- * Copyright (c) 2006, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.impl.preferences
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenStandardPreferencePage
-import org.eclipse.gmf.codegen.gmfgen.StandardPreferencePages
-import xpt.Common
-
-//DOCUMENTATION: PapyrusGencode
-//change the superclass and the initialization
-
-@Singleton class StandardPage extends impl.preferences.StandardPage {
- @Inject extension Common;
-
-
- override Main(GenStandardPreferencePage it) '''
- «copyright(it.diagram.editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment»
- public class «className(it)» «extendsList(it)» «implementsList(it)» {
-
- «generatedMemberComment»
- public «className(it)»() {
- setPreferenceStore(«getDiagram().editorGen.plugin.activatorQualifiedClassName».getInstance().getPreferenceStore());
- «IF StandardPreferencePages.GENERAL_LITERAL == kind»
- setPreferenceKey(«getDiagram().editPartsPackageName».«getDiagram().editPartClassName».MODEL_ID);
- «ENDIF»
- }
- }
- '''
-
- override extendsList(GenStandardPreferencePage it) '''
- «IF kind == StandardPreferencePages::GENERAL_LITERAL»
- extends org.eclipse.papyrus.infra.gmfdiag.preferences.pages.DiagramPreferencePage«»
- «ELSEIF kind == StandardPreferencePages::APPEARANCE_LITERAL»
- extends org.eclipse.gmf.runtime.diagram.ui.preferences.AppearancePreferencePage«»
- «ELSEIF kind == StandardPreferencePages::CONNECTIONS_LITERAL»
- extends org.eclipse.gmf.runtime.diagram.ui.preferences.ConnectionsPreferencePage«»
- «ELSEIF kind == StandardPreferencePages::PRINTING_LITERAL»
- extends org.eclipse.gmf.runtime.diagram.ui.preferences.PrintingPreferencePage«»
- «ELSEIF kind == StandardPreferencePages::RULERS_AND_GRID_LITERAL»
- extends org.eclipse.gmf.runtime.diagram.ui.preferences.RulerGridPreferencePage«»
- «ENDIF»
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/Facility.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/Facility.xtend
deleted file mode 100644
index 7d9127b2272..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/Facility.xtend
+++ /dev/null
@@ -1,32 +0,0 @@
-package aspects.metamodel;
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.Facility_qvto
-import org.eclipse.emf.codegen.ecore.genmodel.GenPackage
-import org.eclipse.gmf.codegen.gmfgen.DynamicModelAccess
-import xpt.Common
-
-@Singleton class Facility extends metamodel.Facility {
-
- @Inject extension Common;
- @Inject extension Facility_qvto;
-
-
-
-override getMethod(GenPackage it, DynamicModelAccess dma)'''
- «generatedMemberComment('@throws IllegalStateException if no EPackage with given URI is registered.')»
- public static «className(dma)» get«getNameToken(it)»() {
- if («fieldName(it)» == null) {
- org.eclipse.emf.ecore.EPackage pkg = getRegistry().getEPackage("«getEcorePackage().nsURI»");
- if (pkg == null) {
- throw new IllegalStateException("Package «getEcorePackage().name»(«getEcorePackage().nsURI») not found");
- }
- «fieldName(it)» = new «className(dma)»(pkg);
- «fieldName(it)».init«getNameToken(it)»();
- }
- return «fieldName(it)»;
- }
-'''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/MetaModel.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/MetaModel.xtend
deleted file mode 100644
index 6c597db0afb..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/metamodel/MetaModel.xtend
+++ /dev/null
@@ -1,16 +0,0 @@
-package aspects.metamodel
-
-import org.eclipse.emf.codegen.ecore.genmodel.GenClass
-import org.eclipse.emf.codegen.ecore.genmodel.GenFeature
-import com.google.inject.Inject
-import metamodel.MetaModel_qvto
-import com.google.inject.Singleton
-
-@Singleton class MetaModel extends metamodel.MetaModel {
-
- @Inject extension MetaModel_qvto;
-
- override DeclareAndAssign2(GenClass it, String assignee, String src, GenClass srcMetaClass, GenFeature srcFeature, String srcExt, boolean needCast) //
- '''«getQualifiedInterfaceName(it)» «assignee» = «getFeatureValue(srcFeature, src, srcMetaClass)».«srcExt»;'''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/parsers/PredefinedParser.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/parsers/PredefinedParser.xtend
deleted file mode 100755
index 881e7e7edf0..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/parsers/PredefinedParser.xtend
+++ /dev/null
@@ -1,65 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 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:
- * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - Initial API and implementation
- * Nicolas FAUVERGUE (ALL4TEC) nicolas.fauvergue@all4tec.net - Bug 496905
- * Gabriel Pascual (ALL4TEC) gabriel.pascual@all4tec.net - Bug 464625
- *****************************************************************************/
-package aspects.parsers
-
-import com.google.inject.Singleton
-
-@Singleton class PredefinedParser extends parsers.PredefinedParser{
-
- override def extendsList(org.eclipse.gmf.codegen.gmfgen.PredefinedParser it) //
- '''extends org.eclipse.papyrus.infra.gmfdiag.common.parsers.AbstractElementTypeBasedAttributeParser'''
-
- override def additions(org.eclipse.gmf.codegen.gmfgen.PredefinedParser it) //
- '''
- /**
- * @generated
- * {@inheritDoc}
- * @see org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.parsers.AbstractFeatureParser#getModificationCommand(org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EStructuralFeature, java.lang.Object)
- */
- @Override
- protected org.eclipse.gmf.runtime.common.core.command.ICommand getModificationCommand(final org.eclipse.emf.ecore.EObject element, final org.eclipse.emf.ecore.EStructuralFeature feature, final Object value) {
- org.eclipse.gmf.runtime.common.core.command.ICommand result = null;
-
- // If the feature to edit is the name, check that this is not really the internationalization to edit and not the name
- if (feature.equals(org.eclipse.uml2.uml.UMLPackage.eINSTANCE.getNamedElement_Name())) {
- if (org.eclipse.papyrus.infra.internationalization.common.utils.InternationalizationPreferencesUtils.getInternationalizationPreference(element) && null != org.eclipse.papyrus.uml.internationalization.utils.utils.UMLLabelInternationalization.getInstance().getLabelWithoutUML((org.eclipse.uml2.uml.NamedElement) element)) {
- final org.eclipse.papyrus.infra.core.resource.ModelSet modelSet = (org.eclipse.papyrus.infra.core.resource.ModelSet) element.eResource().getResourceSet();
- if (null != modelSet) {
- result = new org.eclipse.papyrus.infra.emf.gmf.command.EMFtoGMFCommandWrapper(UMLLabelInternationalization.getInstance().getSetLabelCommand(modelSet.getTransactionalEditingDomain(), (org.eclipse.uml2.uml.NamedElement) element, (String) value, null));
- }
- }
- }
-
- return null != result ? result : super.getModificationCommand(element, feature, value);
- }
-
- /**
- * @generated
- * {@inheritDoc}
- * @see org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.parsers.AbstractAttributeParser#getValue(org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EStructuralFeature)
- */
- @Override
- protected Object getValue(final org.eclipse.emf.ecore.EObject element, final org.eclipse.emf.ecore.EStructuralFeature feature) {
- Object result = null;
-
- if(element instanceof org.eclipse.uml2.uml.NamedElement && feature.equals(org.eclipse.uml2.uml.UMLPackage.eINSTANCE.getNamedElement_Name())){
- if (org.eclipse.papyrus.infra.internationalization.common.utils.InternationalizationPreferencesUtils.getInternationalizationPreference(element) && null != org.eclipse.papyrus.uml.internationalization.utils.utils.UMLLabelInternationalization.getInstance().getLabelWithoutUML((org.eclipse.uml2.uml.NamedElement)element)) {
- result = UMLLabelInternationalization.getInstance().getLabelWithoutUML((org.eclipse.uml2.uml.NamedElement)element);
- }
- }
-
- return null != result ? result : super.getValue(element, feature);
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/CodeStyle.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/CodeStyle.xtend
deleted file mode 100644
index 7b56ab74a76..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/CodeStyle.xtend
+++ /dev/null
@@ -1,12 +0,0 @@
-package aspects.xpt
-
-import org.eclipse.gmf.codegen.gmfgen.GenCommonBase
-import com.google.inject.Singleton
-
-@Singleton class CodeStyle extends xpt.CodeStyle {
-
- override overrideI(GenCommonBase xptSelf) '''
- @Override
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/Common.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/Common.xtend
deleted file mode 100644
index 58a5807bc5e..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/Common.xtend
+++ /dev/null
@@ -1,44 +0,0 @@
-/**
- * Copyright (c) 2006-2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt;
-
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenCommonBase
-import org.eclipse.gmf.codegen.gmfgen.GenEditorGenerator
-import org.eclipse.papyrus.papyrusgmfgenextension.VisualIDOverride
-
-@Singleton class Common extends xpt.Common {
- override copyright(GenEditorGenerator it)
- '''
- «IF copyrightText != null»
- /**
- * «copyrightText.replaceAll('\n', '\n * ')»
- */
- «ENDIF»
- '''
-
- def String stringVisualID(GenCommonBase it) {
- if (it.eResource.allContents.filter(typeof (VisualIDOverride)).exists(v|v.genView == it))
- it.eResource.allContents.filter(typeof (VisualIDOverride)).findFirst(v|v.genView == it).visualID
- else
- it.visualID.toString
- }
-
- def String stringUniqueIdentifier(GenCommonBase it) {
- if (it.eResource.allContents.filter(typeof (VisualIDOverride)).exists(v|v.genView == it))
- it.eResource.allContents.filter(typeof (VisualIDOverride)).findFirst(v|v.genView == it).visualID
- else
- it.uniqueIdentifier
- }
-}
-
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/QualifiedClassNameProvider.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/QualifiedClassNameProvider.xtend
deleted file mode 100644
index cb73c870eef..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/QualifiedClassNameProvider.xtend
+++ /dev/null
@@ -1,30 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 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 aspects.xpt
-
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenCompartment
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-
-@Singleton class QualifiedClassNameProvider extends xpt.QualifiedClassNameProvider {
-
-
-
-
- override dispatch getItemSemanticEditPolicyQualifiedClassName(GenDiagram it) '''org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultCompartmentSemanticEditPolicy'''
- override dispatch getItemSemanticEditPolicyQualifiedClassName(GenCompartment it) '''org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultCompartmentSemanticEditPolicy'''
- override dispatch getItemSemanticEditPolicyQualifiedClassName(GenLink it) '''org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultSemanticEditPolicy'''
- override dispatch getItemSemanticEditPolicyQualifiedClassName(GenNode it) '''org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultSemanticEditPolicy'''
-
-
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateLinkUtils.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateLinkUtils.xtend
deleted file mode 100644
index 3017f6719d9..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateLinkUtils.xtend
+++ /dev/null
@@ -1,82 +0,0 @@
-/**
- * Copyright (c) 2007-2012 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.commands
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.gmf.codegen.gmfgen.LinkModelFacet
-import org.eclipse.gmf.codegen.gmfgen.TypeLinkModelFacet
-import xpt.Common
-import xpt.diagram.Utils_qvto
-
-@Singleton class CreateLinkUtils extends xpt.diagram.commands.CreateLinkUtils {
- @Inject extension Common;
- @Inject extension Utils_qvto;
-
- @Inject MetaModel xptMetaModel;
-
-
- /**
- * Fields of command that creates link.
- */
- override dispatch fields(LinkModelFacet it) '''
- «extraLineBreak»
- «generatedMemberComment()»
- protected final org.eclipse.emf.ecore.EObject source;
-
- «generatedMemberComment()»
- protected final org.eclipse.emf.ecore.EObject target;
- '''
-
- override dispatch fields(TypeLinkModelFacet it) '''
- «extraLineBreak»
- «generatedMemberComment()»
- protected final org.eclipse.emf.ecore.EObject source;
-
- «generatedMemberComment()»
- protected final org.eclipse.emf.ecore.EObject target;
- «IF hasContainerOtherThanSource(it)»
-
- «generatedMemberComment()»
- protected «xptMetaModel.QualifiedClassName(it.containmentMetaFeature.genClass)» container;
- «ENDIF»
- '''
-
- override dispatch containerAccessor(TypeLinkModelFacet it) '''
- «IF hasContainerOtherThanSource(it)»
-
- «generatedMemberComment()»
- public «xptMetaModel.QualifiedClassName(it.containmentMetaFeature.genClass)» getContainer() {
- return container;
- }
-
- «generatedMemberComment(
- 'Default approach is to traverse ancestors of the source to find instance of container.\n' + 'Modify with appropriate logic.'
- )»
- protected «xptMetaModel.QualifiedClassName(it.containmentMetaFeature.genClass)» deduceContainer(org.eclipse.emf.ecore.EObject source, org.eclipse.emf.ecore.EObject target) {
- // Find container element for the new link.
- // Climb up by containment hierarchy starting from the source
- // and return the first element that is instance of the container class.
- for (org.eclipse.emf.ecore.EObject element = source; element != null; element = element.eContainer()) {
- if («xptMetaModel.IsInstance(containmentMetaFeature.genClass, 'element')») {
- return «xptMetaModel.CastEObject(it.containmentMetaFeature.genClass, 'element')»;
- }
- }
- return null;
- }
- «ENDIF»
-
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateNodeCommand.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateNodeCommand.xtend
deleted file mode 100644
index ab940ff8036..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/CreateNodeCommand.xtend
+++ /dev/null
@@ -1,227 +0,0 @@
-/**
- * Copyright (c) 2007, 2010 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.commands
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import org.eclipse.gmf.codegen.gmfgen.TypeModelFacet
-import xpt.Common
-import xpt.OclMigrationProblems_qvto
-import xpt.diagram.Utils_qvto
-
-@Singleton class CreateNodeCommand extends xpt.diagram.commands.CreateNodeCommand {
- @Inject extension Common;
-
- @Inject extension OclMigrationProblems_qvto;
- @Inject extension MetaModel
- @Inject extension Utils_qvto;
-
-
- @Inject MetaModel xptMetaModel;
-
- override CreateNodeCommand(GenNode it) '''
- «copyright(it.diagram.editorGen)»
- package «packageName(it)»;
-
-
-
- «generatedClassComment()»
- public class «className(it)» extends org.eclipse.gmf.runtime.emf.type.core.commands.EditElementCommand {
-
- «IF ! it.modelFacet.isPhantomElement()»
- «generatedMemberComment()»
- private org.eclipse.gmf.runtime.notation.Diagram diagram = null;
- «ENDIF»
-
- «_constructor(it)»
-
- «getElementToEdit(it)»
-
- «canExecuteMethod(it)»
-
- «doExecuteWithResultMethod(it)»
-
- «doConfigureMethod(it)»
-
- «additions(it)»
- }
- '''
-
- override _constructor(GenNode it) '''
- «generatedMemberComment()»
- public «className(it)»(org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest req, org.eclipse.gmf.runtime.notation.Diagram diagram) {
- super(req.getLabel(), null, req);
- «IF ! it.modelFacet.isPhantomElement()»
- this.diagram = diagram;
- «ENDIF»
- }
- '''
-
-// override CreateNodeCommand(TypeModelFacet it) '''
-// «copyright(ownerGenNode(it).diagram.editorGen)»
-// package «packageName(it)»;
-//
-// «generatedClassComment()»
-// public class «className(it)» extends org.eclipse.gmf.runtime.emf.type.core.commands.EditElementCommand {
-//««« Mutating canvas auxiliary
-// «generatedMemberComment»
-// private org.eclipse.emf.ecore.EClass eClass = null;
-// «generatedMemberComment»
-// private org.eclipse.emf.ecore.EObject eObject = null;
-// ««« Mutating canvas auxiliary constructor
-// «generatedMemberComment»
-// public «ownerGenNode(it).createCommandClassName»(org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest req, org.eclipse.emf.ecore.EObject eObject) {
-// super(req.getLabel(), null, req);
-// this.eObject = eObject;
-// this.eClass = eObject != null ? eObject.eClass() : null;
-// }
-// ««« Mutating canvas auxiliary builder
-// «generatedMemberComment»
-// public static «ownerGenNode(it).createCommandClassName» create(org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest req, org.eclipse.emf.ecore.EObject eObject) {
-// return new «ownerGenNode(it).createCommandClassName»(req, eObject);
-// }
-// « _constructor(it)»
-// « getElementToEdit(it)»
-// « canExecuteMethod(it)»
-// « doExecuteWithResultMethod(it)»
-// « doConfigureMethod(it)»
-// }
-// '''
-//
-//
-//
-// /**
-// * TODO: either use setElementToEdit, or generate downcasted version (which may be troublesome if containment and child features point to a different parent)
-// */
-// override getElementToEdit(TypeModelFacet it) '''
-// «generatedMemberComment('FIXME: replace with setElementToEdit()')»
-// protected org.eclipse.emf.ecore.EObject getElementToEdit() {
-//
-// ««« Mutating canvas helper
-// org.eclipse.emf.ecore.EObject container =
-// ((org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest) getRequest()).getContainer();
-// if (container instanceof org.eclipse.gmf.runtime.notation.View) {
-// container = ((org.eclipse.gmf.runtime.notation.View) container).getElement();
-// }
-// if (container != null) {
-// return container;
-// }
-// return eObject;
-//
-// }
-// '''
-
- // [AbstractElement] Modified for Abstract domain element
- override doExecuteWithResultMethod(GenNode it) '''
- «generatedMemberComment()»
- protected org.eclipse.gmf.runtime.common.core.command.CommandResult doExecuteWithResult(org.eclipse.core.runtime.IProgressMonitor monitor, org.eclipse.core.runtime.IAdaptable info) throws org.eclipse.core.commands.ExecutionException {
- ««« [AbstractElement] START
-
- «IF it.modelFacet.metaClass.ecoreClass.abstract != true»
- ««« [AbstractElement] END
- «IF it.modelFacet.isPhantomElement()»
- «phantomElementCreation(it.modelFacet, it, 'newElement')»
- «ELSE»
- «normalElementCreation(it.modelFacet, it, 'newElement')»
- «ENDIF»
- «extraLineBreak»
- «initialize(it.modelFacet, it, 'newElement')»
- «IF true/*FIXME boolean needsExternalConfiguration*/»
- «extraLineBreak»
- doConfigure(newElement, monitor, info);
- «extraLineBreak»
- «ENDIF»
- ((org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest) getRequest()).setNewElement(«xptMetaModel.
- DowncastToEObject(it.modelFacet.metaClass, 'newElement')»);
- return org.eclipse.gmf.runtime.common.core.command.CommandResult.newOKCommandResult(newElement);
- }
- ««« [AbstractElement] START
- «ELSE»
- throw new UnsupportedOperationException("Unimplemented operation (abstract domain element).");
- }
- «ENDIF»
- ««« [AbstractElement] END
- '''
-
-
- override canExecute_Normal(TypeModelFacet it) '''
- «IF containmentMetaFeature != null»
- «IF containmentMetaFeature.ecoreFeature != null»
- «IF ! isUnbounded(containmentMetaFeature.ecoreFeature) || (childMetaFeature != containmentMetaFeature && ! isUnbounded(childMetaFeature.ecoreFeature))»
- «IF ! isUnbounded(containmentMetaFeature.ecoreFeature)»
- «DeclareAndAssign(containmentMetaFeature.genClass,'container', 'getElementToEdit()') »
- «IF isSingleValued(containmentMetaFeature.ecoreFeature)»
- if («getFeatureValue(containmentMetaFeature,'container', containmentMetaFeature.genClass) » != null) {
- «ELSE»
- if (« getFeatureValue(containmentMetaFeature,'container', containmentMetaFeature.genClass)».size() >= «containmentMetaFeature.ecoreFeature.upperBound») {
- «ENDIF»
- return false;
- }
- «ENDIF»
- «IF childMetaFeature != containmentMetaFeature && ! isUnbounded(childMetaFeature.ecoreFeature)»
- «IF isSingleValued(childMetaFeature.ecoreFeature)»
- if («getFeatureValue(childMetaFeature,'container', containmentMetaFeature.genClass) » != null) {
- «ELSE»
- if («getFeatureValue(childMetaFeature,'container', containmentMetaFeature.genClass) ».size() >= «childMetaFeature.ecoreFeature.upperBound») {
- «ENDIF»
- return false;
- }
- «ENDIF»
- «ENDIF»
- «ENDIF»
- «ENDIF»
-
- org.eclipse.emf.ecore.EObject target = getElementToEdit();
- org.eclipse.papyrus.infra.viewpoints.policy.ModelAddData data = org.eclipse.papyrus.infra.viewpoints.policy.PolicyChecker.getFor(target).getChildAddData(diagram, target.eClass(), «MetaClass(metaClass)»);
- return data.isPermitted();
-
- '''
-
-
- override normalElementCreation(TypeModelFacet it, GenNode node, String varName) '''
- «xptMetaModel.NewInstance(it.metaClass, varName)»
-
- org.eclipse.emf.ecore.EObject target = getElementToEdit();
- org.eclipse.papyrus.infra.viewpoints.policy.ModelAddData data = org.eclipse.papyrus.infra.viewpoints.policy.PolicyChecker.getFor(target).getChildAddData(diagram, target, «varName»);
- if (data.isPermitted()) {
- if (data.isPathDefined()) {
- if (!data.execute(target, «varName»)) {
- return org.eclipse.gmf.runtime.common.core.command.CommandResult.newErrorCommandResult("Failed to follow the policy-specified for the insertion of the new element");
- }
- } else {
- «extraLineBreak»
- «IF containmentMetaFeature != null»
- «xptMetaModel.DeclareAndAssign(it.containmentMetaFeature.genClass, 'qualifiedTarget', 'target')»
- «xptMetaModel.modifyFeature(containmentMetaFeature, 'qualifiedTarget', containmentMetaFeature.genClass, varName)»
- «ELSE»
- //
- // FIXME no containment feature found in the genmodel, toolsmith need to manually write code here to add «varName» to a parent
- //
- «ENDIF»
-
- }
- } else {
- return org.eclipse.gmf.runtime.common.core.command.CommandResult.newErrorCommandResult("The active policy restricts the addition of this element");
- }
-
- «IF hasExplicitChildFeature(it)»
- «xptMetaModel.DeclareAndAssign(it.childMetaFeature.genClass, 'childHolder', 'getElementToEdit()')»
- «xptMetaModel.modifyFeature(it.childMetaFeature, 'childHolder', childMetaFeature.genClass, varName)»
- «ENDIF»
- '''
-
-
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/ReorientLinkUtils.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/ReorientLinkUtils.xtend
deleted file mode 100644
index acc4f6bfbf4..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/commands/ReorientLinkUtils.xtend
+++ /dev/null
@@ -1,65 +0,0 @@
-package aspects.xpt.diagram.commands
-
-import org.eclipse.gmf.codegen.gmfgen.LinkModelFacet
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import xpt.Common
-import com.google.inject.Inject
-import com.google.inject.Singleton
-
-@Singleton class ReorientLinkUtils extends xpt.diagram.commands.ReorientLinkUtils {
-
- @Inject extension Common
-
- override canReorient(LinkModelFacet it, GenLink link) '''
- «generatedMemberComment()»
- public boolean canExecute() {
- «checkLinkValidity(it)»
- if (reorientDirection == org.eclipse.gmf.runtime.emf.type.core.requests.ReorientRequest.REORIENT_SOURCE) {
- return canReorientSource();
- }
- if (reorientDirection == org.eclipse.gmf.runtime.emf.type.core.requests.ReorientRequest.REORIENT_TARGET) {
- return canReorientTarget();
- }
- return false;
- }
-
- «generatedMemberComment()»
- protected boolean canReorientSource() {
- «checkSourceRequestValidity(it, link)»
- }
-
- «generatedMemberComment()»
- protected boolean canReorientTarget() {
- «checkTargetRequestValidity(it, link)»
- }
- '''
-
- override reorient(LinkModelFacet it) '''
-
- «generatedMemberComment()»
- protected org.eclipse.gmf.runtime.common.core.command.CommandResult doExecuteWithResult(
- org.eclipse.core.runtime.IProgressMonitor monitor, org.eclipse.core.runtime.IAdaptable info)
- throws org.eclipse.core.commands.ExecutionException {
- if (!canExecute()) {
- throw new org.eclipse.core.commands.ExecutionException("Invalid arguments in reorient link command"); «nonNLS()»
- }
- if (reorientDirection == org.eclipse.gmf.runtime.emf.type.core.requests.ReorientRequest.REORIENT_SOURCE) {
- return reorientSource();
- }
- if (reorientDirection == org.eclipse.gmf.runtime.emf.type.core.requests.ReorientRequest.REORIENT_TARGET) {
- return reorientTarget();
- }
- throw new IllegalStateException();
- }
-
- «generatedMemberComment()»
- protected org.eclipse.gmf.runtime.common.core.command.CommandResult reorientSource() throws org.eclipse.core.commands.ExecutionException {
- «reorientSource(it)»
- }
-
- «generatedMemberComment()»
- protected org.eclipse.gmf.runtime.common.core.command.CommandResult reorientTarget() throws org.eclipse.core.commands.ExecutionException {
- «reorientTarget(it)»
- }
- '''
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/BaseEditHelper.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/BaseEditHelper.xtend
deleted file mode 100755
index 491519a8f33..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/BaseEditHelper.xtend
+++ /dev/null
@@ -1,25 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 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:
- * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - Initial API and implementation
- *****************************************************************************/
-package aspects.xpt.diagram.edithelpers;
-
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-
-public class BaseEditHelper extends xpt.diagram.edithelpers.BaseEditHelper {
-
- override superClass(GenDiagram it) '''org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.edit.helpers.GeneratedEditHelperBase'''
-
- override def editPolicyCommandConstant(GenDiagram it) '''org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.edit.helpers.GeneratedEditHelperBase.EDIT_POLICY_COMMAND'''
-
- override def contextElementTypeConstant(GenDiagram it) '''org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.edit.helpers.GeneratedEditHelperBase.CONTEXT_ELEMENT_TYPE'''
-
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/EditHelper.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/EditHelper.xtend
deleted file mode 100644
index 59987137756..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/edithelpers/EditHelper.xtend
+++ /dev/null
@@ -1,37 +0,0 @@
-/**
- * Copyright (c) 2006-2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.edithelpers;
-
-import com.google.inject.Inject
-import org.eclipse.gmf.codegen.gmfgen.MetamodelType
-import utils.EditHelperUtils_qvto
-import xpt.Common
-
-public class EditHelper extends xpt.diagram.edithelpers.EditHelper {
- @Inject extension Common;
- @Inject extension EditHelperUtils_qvto
-
-
-
-
- override EditHelper(MetamodelType it) '''
- «copyright(diagramElement.diagram.editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment»
- public class «editHelperClassName» extends «getBaseEditHelperFullName(diagramElement.getDiagram())» {
- «additions(it)»
- }
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/Common.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/Common.xtend
deleted file mode 100644
index 992cfd621c7..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/Common.xtend
+++ /dev/null
@@ -1,58 +0,0 @@
-/**
- * Copyright (c) 2006, 2010 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Patrick Tessier (CEA LIST)
- */
-package aspects.xpt.diagram.editparts
-
-import aspects.xpt.QualifiedClassNameProvider
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenCommonBase
-import org.eclipse.gmf.codegen.gmfgen.GenContainerBase
-
-//Documentation: PapyrusGenCode
-//This template has been modified in order to remove canonical ediPolicies
-
-@Singleton class Common extends xpt.diagram.editparts.Common {
- @Inject extension aspects.xpt.Common;
-
- @Inject QualifiedClassNameProvider qualifiedClassNameProvider;
-
- override installCanonicalEditPolicy(GenContainerBase it) '''
- «IF it.needsCanonicalEditPolicy»
- ««« BEGIN: PapyrusGenCode
- ««« Used to remove at each time canonical editpolicies
- //in Papyrus diagrams are not strongly synchronised
- //installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.CANONICAL_ROLE, new «getCanonicalEditPolicyQualifiedClassName()»());
- ««« END: PapyrusGenCode
-
- «ENDIF»
- '''
-
- override creationEditPolicyNewInstance(GenCommonBase it)
- '''new org.eclipse.papyrus.infra.gmfdiag.common.editpolicies.DefaultCreationEditPolicy()'''
-
-
- override installSemanticEditPolicy(GenCommonBase it) '''
- «IF sansDomain»
- removeEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.SEMANTIC_ROLE);
- «ELSE»
- installEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.SEMANTIC_ROLE, new «qualifiedClassNameProvider.getItemSemanticEditPolicyQualifiedClassName(it)»());
- «ENDIF»
- '''
-
- override def visualIDConstant(GenCommonBase it) '''
- «generatedMemberComment»
- public static final String VISUAL_ID = "«stringVisualID»";
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/EditPartFactory.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/EditPartFactory.xtend
deleted file mode 100644
index 4d9935befe9..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editparts/EditPartFactory.xtend
+++ /dev/null
@@ -1,75 +0,0 @@
-/**
- * Copyright (c) 2006, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.editparts
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-
-//DOCUMENTATION: PapyrusGencode
-//change to manage the figure of the comment
-@Singleton class EditPartFactory extends xpt.diagram.editparts.EditPartFactory {
-
- @Inject extension xpt.Common;
-
-
- override getTextCellEditorLocator(GenDiagram it) '''
- «generatedMemberComment»
- public static org.eclipse.gef.tools.CellEditorLocator getTextCellEditorLocator(
- org.eclipse.gmf.runtime.diagram.ui.editparts.ITextAwareEditPart source) {
- if (source.getFigure() instanceof org.eclipse.papyrus.uml.diagram.common.figure.node.IMultilineEditableFigure){
- return new MultilineCellEditorLocator(
- (org.eclipse.papyrus.uml.diagram.common.figure.node.IMultilineEditableFigure) source.getFigure());
- }
- else {
- return org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.directedit.locator.CellEditorLocatorAccess.INSTANCE.getTextCellEditorLocator(source);
-
- }
- }
-
-
- «generatedClassComment»
- static private class MultilineCellEditorLocator implements org.eclipse.gef.tools.CellEditorLocator {
-
- «generatedClassComment»
- private org.eclipse.papyrus.uml.diagram.common.figure.node.IMultilineEditableFigure multilineEditableFigure;
-
- «generatedClassComment»
- public MultilineCellEditorLocator(org.eclipse.papyrus.uml.diagram.common.figure.node.IMultilineEditableFigure figure) {
- this.multilineEditableFigure = figure;
- }
-
- «generatedClassComment»
- public org.eclipse.papyrus.uml.diagram.common.figure.node.IMultilineEditableFigure getMultilineEditableFigure() {
- return multilineEditableFigure;
- }
-
- «generatedClassComment»
- public void relocate(org.eclipse.jface.viewers.CellEditor celleditor) {
- org.eclipse.swt.widgets.Text text = (org.eclipse.swt.widgets.Text) celleditor.getControl();
- org.eclipse.draw2d.geometry.Rectangle rect = getMultilineEditableFigure().getBounds().getCopy();
- rect.x=getMultilineEditableFigure().getEditionLocation().x;
- rect.y=getMultilineEditableFigure().getEditionLocation().y;
- getMultilineEditableFigure().translateToAbsolute(rect);
- if (getMultilineEditableFigure().getText().length() > 0) {
- rect.setSize(new org.eclipse.draw2d.geometry.Dimension(text.computeSize(rect.width,
- org.eclipse.swt.SWT.DEFAULT)));
- }
- if (!rect.equals(new org.eclipse.draw2d.geometry.Rectangle(text.getBounds()))) {
- text.setBounds(rect.x, rect.y, rect.width, rect.height);
- }
- }
- }
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/BaseItemSemanticEditPolicy.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/BaseItemSemanticEditPolicy.xtend
deleted file mode 100644
index e211ac08408..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/BaseItemSemanticEditPolicy.xtend
+++ /dev/null
@@ -1,387 +0,0 @@
-/**
- * Copyright (c) 2007, 2014 Borland Software Corporation, Christian W. Damus, and others.
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Christian W. Damus - bug 451230
- */
-package aspects.xpt.diagram.editpolicies
-
-import aspects.xpt.Common
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.emf.codegen.ecore.genmodel.GenClass
-import org.eclipse.emf.codegen.ecore.genmodel.GenFeature
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.TypeLinkModelFacet
-import org.eclipse.papyrus.papyrusgmfgenextension.GenerateUsingElementTypeCreationCommand
-import plugin.Activator
-import xpt.OclMigrationProblems_qvto
-import xpt.editor.VisualIDRegistry
-import xpt.providers.ElementTypes
-
-//Documentation: PapyrusGenCode
-//This tamplate has been modified in order to allow the moving command
-@Singleton class BaseItemSemanticEditPolicy extends xpt.diagram.editpolicies.BaseItemSemanticEditPolicy {
- @Inject extension Common;
- @Inject Activator xptPluginActivator;
- @Inject extension VisualIDRegistry
- @Inject ElementTypes xptElementTypes;
- @Inject extension OclMigrationProblems_qvto;
- @Inject extension xpt.diagram.editpolicies.Utils_qvto
- @Inject MetaModel xptMetaModel;
-
- override BaseItemSemanticEditPolicy(GenDiagram it) '''
-«copyright(editorGen)»
-package «packageName(it)»;
-
-«generatedClassComment()»
-public class «className(it)» extends org.eclipse.gmf.runtime.diagram.ui.editpolicies.SemanticEditPolicy {
-
- «attributes(it)»
-
- «constructor(it)»
-
- «generatedMemberComment(
- 'Extended request data key to hold editpart visual id.\n' + 'Add visual id of edited editpart to extended data of the request\n' + 'so command switch can decide what kind of diagram element is being edited.\n' + 'It is done in those cases when it\'s not possible to deduce diagram\n' + 'element kind from domain element.\n' + 'Add the reoriented view to the request extended data so that the view\n ' + 'currently edited can be distinguished from other views of the same element\n ' +
- 'and these latter possibly removed if they become inconsistent after reconnect\n'
- )»
- @SuppressWarnings("unchecked")
- public org.eclipse.gef.commands.Command getCommand(org.eclipse.gef.Request request) {
- if (request instanceof org.eclipse.gef.requests.ReconnectRequest) {
- Object view = ((org.eclipse.gef.requests.ReconnectRequest) request).getConnectionEditPart().getModel();
- if (view instanceof org.eclipse.gmf.runtime.notation.View) {
- String id = «getVisualIDMethodCall(it)»((org.eclipse.gmf.runtime.notation.View) view);
- request.getExtendedData().put(VISUAL_ID_KEY, id);
- request.getExtendedData().put(GRAPHICAL_RECONNECTED_EDGE, view);
- }
- }
- return super.getCommand(request);
- }
-
- «generatedMemberComment('Returns visual id from request parameters.')»
- protected String getVisualID(org.eclipse.gmf.runtime.emf.type.core.requests.IEditCommandRequest request) {
- return (String) request.getParameter(VISUAL_ID_KEY);
- }
-
- «semanticPart(it)»
-
- «generatedMemberComment('Returns editing domain from the host edit part.')»
- protected org.eclipse.emf.transaction.TransactionalEditingDomain getEditingDomain() {
- return ((org.eclipse.gmf.runtime.diagram.ui.editparts.IGraphicalEditPart) getHost()).getEditingDomain();
- }
-
- «addDestroyShortcutsCommand(it)»
-
-«IF links.exists(link|!link.sansDomain)»
- «linkConstraints(it)»
-«ENDIF»
-
- «additions(it)»
-}
-'''
-
-override def addDestroyShortcutsCommand(GenDiagram it) '''
- «generatedMemberComment('Clean all shortcuts to the host element from the same diagram')»
- protected void addDestroyShortcutsCommand(org.eclipse.gmf.runtime.common.core.command.ICompositeCommand cmd, org.eclipse.gmf.runtime.notation.View view) {
- «_assert('view.getEAnnotation(\"Shortcut\") == null')»
- for (java.util.Iterator<?> it = view.getDiagram().getChildren().iterator(); it.hasNext();) {
- org.eclipse.gmf.runtime.notation.View nextView = (org.eclipse.gmf.runtime.notation.View) it.next();
- if (nextView.getEAnnotation("Shortcut") == null || !nextView.isSetElement() || nextView.getElement() != view.getElement()) { «nonNLS()»
- continue;
- }
- cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), nextView));
- }
- }
-'''
-
- override attributes(GenDiagram it) '''
- «generatedMemberComment('Extended request data key to hold editpart visual id.')»
- public static final String VISUAL_ID_KEY = "visual_id"; «nonNLS()»
- «generatedMemberComment('Extended request data key to hold the edge view during a reconnect request.')»
- public static final String GRAPHICAL_RECONNECTED_EDGE = "graphical_edge"; «nonNLS»
- «generatedMemberComment()»
- private final org.eclipse.gmf.runtime.emf.type.core.IElementType myElementType;
- '''
-
- override semanticPart(GenDiagram it) '''
- «getSemanticCommand(it)»
-
- «addDeleteViewCommand(it)»
-
- «getEditHelperCommand(it)»
-
- «getContextElementType(it)»
-
- «getSemanticCommandSwitch(it)»
-
- «getConfigureCommand(it)»
-
- «getCreateRelationshipCommand(it)»
-
- «getCreateCommand(it)»
-
- «getCreateSemanticServiceEditCommand(it)»
-
- «getSetCommand(it)»
-
- «getEditContextCommand(it)»
-
- «getDestroyElementCommand(it)»
-
- «getDestroyReferenceCommand(it)»
-
- «getDuplicateCommand(it)»
-
- «getMoveCommand(it)»
-
- «getReorientReferenceRelationshipCommand(it)»
-
- «getReorientRelationshipCommand(it)»
-
- «getGEFWrapper(it)»
- '''
-
- override getContextElementType(GenDiagram it) '''
- «generatedMemberComment()»
- protected org.eclipse.gmf.runtime.emf.type.core.IElementType getContextElementType(org.eclipse.gmf.runtime.emf.type.core.requests.IEditCommandRequest request) {
- org.eclipse.gmf.runtime.emf.type.core.IElementType requestContextElementType = «xptElementTypes.qualifiedClassName(it)».getElementType(getVisualID(request));
- return requestContextElementType != null ? requestContextElementType : myElementType;
- }
- '''
-
- override getCreateRelationshipCommand(GenDiagram it) '''
-«generatedMemberComment()»
-protected org.eclipse.gef.commands.Command getCreateRelationshipCommand(org.eclipse.gmf.runtime.emf.type.core.requests.CreateRelationshipRequest req) {
- «IF it.eResource.allContents.filter(typeof(GenerateUsingElementTypeCreationCommand)).size < 1»
- return null;
- «ENDIF»
- «IF it.eResource.allContents.filter(typeof(GenerateUsingElementTypeCreationCommand)).size() > 0»
- org.eclipse.papyrus.infra.services.edit.service.IElementEditService commandService = org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils.getCommandProvider(((org.eclipse.gmf.runtime.diagram.ui.editparts.IGraphicalEditPart)getHost()).resolveSemanticElement());
- if(req.getElementType() != null) {
- commandService = org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils.getCommandProvider(req.getElementType(), req.getClientContext());
- }
-
- if(commandService == null) {
- return org.eclipse.gef.commands.UnexecutableCommand.INSTANCE;
- }
-
- org.eclipse.gmf.runtime.common.core.command.ICommand semanticCommand = commandService.getEditCommand(req);
-
- if((semanticCommand != null) && (semanticCommand.canExecute())) {
- return getGEFWrapper(semanticCommand);
- }
- return org.eclipse.gef.commands.UnexecutableCommand.INSTANCE;
- «ENDIF»
-}
-'''
-
- override getCreateCommand(GenDiagram it) '''
-«generatedMemberComment()»
- protected org.eclipse.gef.commands.Command getCreateCommand(org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest req) {
- org.eclipse.gmf.runtime.emf.type.core.IElementType requestElementType = req.getElementType();
- if (requestElementType instanceof org.eclipse.gmf.runtime.emf.type.core.IElementType) {
- org.eclipse.papyrus.infra.services.edit.service.IElementEditService commandProvider = org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils.getCommandProvider(req.getContainer());
- if (commandProvider != null) {
- org.eclipse.gmf.runtime.common.core.command.ICommand command = commandProvider.getEditCommand(req);
- if (command != null && command.canExecute()) {
- return new org.eclipse.gmf.runtime.diagram.ui.commands.ICommandProxy(command);
- }
- }
- }
- return null;
- }
-'''
-
-
- override getMoveCommand(GenDiagram it) '''
-«generatedMemberComment()»
-protected org.eclipse.gef.commands.Command getMoveCommand(org.eclipse.gmf.runtime.emf.type.core.requests.MoveRequest req) {
- ««« BEGIN: PapyrusGenCode
- ««« add move command
- org.eclipse.emf.ecore.EObject targetCEObject = req.getTargetContainer();
- if(targetCEObject != null) {
- org.eclipse.papyrus.infra.services.edit.service.IElementEditService provider = org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils.getCommandProvider(targetCEObject);
- if(provider != null) {
- org.eclipse.gmf.runtime.common.core.command.ICommand moveCommand = provider.getEditCommand(req);
- if(moveCommand != null) {
- return new org.eclipse.gmf.runtime.diagram.ui.commands.ICommandProxy(moveCommand);
- }
- }
- return org.eclipse.gef.commands.UnexecutableCommand.INSTANCE;
- } else {
- return getGEFWrapper(new org.eclipse.gmf.runtime.emf.type.core.commands.MoveElementsCommand(req));
- }
- ««« END: PapyrusGenCode
-
-}
-'''
-
- /**
- * FIXME need to check constraint's provider to ensure we don't generate a field
- * for e.g. Java (or Literal, which is unlikely, though) expressions
- *
- * [Papyrus Quick Fix] Do not generate field when the expression is provided
- * by a GenJavaExpressionProvider.
- */
- override linkConstraints(GenDiagram it) '''
-
- «generatedMemberComment()»
- public static «getLinkCreationConstraintsClassName()» getLinkConstraints() {
- «getLinkCreationConstraintsClassName()» cached = «xptPluginActivator.instanceAccess(it.editorGen)».getLinkConstraints();
- if (cached == null) {
- «xptPluginActivator.instanceAccess(it.editorGen)».setLinkConstraints(cached = new «getLinkCreationConstraintsClassName()»());
- }
- return cached;
- }
-
-«generatedClassComment()»
-public static class «getLinkCreationConstraintsClassName()» {
-
- «generatedMemberComment»
- public «getLinkCreationConstraintsClassName()»() {«««package-local for the BaseItemSemanticEditPolicy to instantiate. Perhaps, protected is better (i.e. if someone subclasses it?)
- // use static method #getLinkConstraints() to access instance
- }
-
- «FOR nextLink : it.links»
- «canCreate(nextLink)»
- «ENDFOR»
-
- «FOR nextLink : it.links»
- «canExist(nextLink)»
- «ENDFOR»
-}
-'''
-
- /**
- * [MG] extracted from LET statement, @see checkEMFConstraints(TypeLinkModelFacet)
- */
- private def checkChildFeatureBounds(TypeLinkModelFacet it) {
- childMetaFeature != containmentMetaFeature && !isUnbounded(childMetaFeature.ecoreFeature)
- }
-
- def checkEMFConstraints(TypeLinkModelFacet it) '''
-«IF containmentMetaFeature.ecoreFeature != null»
- «IF ! isUnbounded(containmentMetaFeature.ecoreFeature) || checkChildFeatureBounds(it)»
- if («getContainerVariable(it)» != null) {
- «checkEMFConstraints(containmentMetaFeature, it)»
- «IF checkChildFeatureBounds(it)»
- «checkEMFConstraints(childMetaFeature, it)»
- «ENDIF»
- }
- «ENDIF»
-«ENDIF»
-'''
-
- override checkEMFConstraints(GenFeature it, TypeLinkModelFacet modelFacet) '''
-«IF modelFacet.containmentMetaFeature.ecoreFeature != null»
-«IF ! isUnbounded(ecoreFeature)»
-if («featureBoundComparator(it, getContainerVariable(modelFacet), modelFacet.getSourceType())») {
- return false;
-}
-«ENDIF»
-«ENDIF»
-'''
-
- override canCreate(GenLink it) '''
-«generatedMemberComment()»
-public boolean canCreate«stringUniqueIdentifier()»(
-«IF !it.sansDomain»
-«canCreateParameters(it.modelFacet)»
-«ENDIF»
-) {
- «IF !it.sansDomain»
- «checkEMFConstraints(it.modelFacet)»
- «ENDIF»
- return canExist«stringUniqueIdentifier()»(
- «IF !it.sansDomain»
- «canCreateValues(it.modelFacet)»
- «ENDIF»
- );
-}
-'''
-
- override featureBoundsConditionClause(GenFeature it, String targetVar, GenClass targetType) '''
-«««Checking upper bounds if was specified in MM
-«IF ecoreFeature != null»
- «IF ! isUnbounded(ecoreFeature)»«featureBoundComparator(it, targetVar, targetType)»«ENDIF»
- ««« Checking uniqueness in addition if upper bounds != 1
- «IF ! isSingleValued(ecoreFeature) && ! isUnbounded(ecoreFeature)» || «ENDIF»
- ««« Checking uniqueness in if upper bounds !- 1
- «IF ! isSingleValued(ecoreFeature)»«featureUniquenessComparator(it, targetVar, targetType)»«ENDIF»
-«ENDIF»
-'''
-
- override featureBoundComparator(GenFeature it, String featureVar, GenClass featureVarGenClass) '''
- «xptMetaModel.getFeatureValue(it, featureVar, featureVarGenClass)»
- «IF ecoreFeature.upperBound == 1»
- != null
- «ELSE»
- .size() >= «ecoreFeature.upperBound»
- «ENDIF»
- '''
-
- // Generate generic method if using semantic creation command based on element types framework.
- def getCreateSemanticServiceEditCommand(GenDiagram it) '''
-«IF it.eResource.allContents.filter(typeof(GenerateUsingElementTypeCreationCommand)).size > 0»
- «generatedMemberComment»
- protected org.eclipse.gmf.runtime.common.core.command.ICommand getSemanticCreationCommand(org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest req) {
- org.eclipse.papyrus.infra.services.edit.service.IElementEditService commandService = org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils.getCommandProvider(req.getContainer());
- if(commandService == null) {
- return org.eclipse.gmf.runtime.common.core.command.UnexecutableCommand.INSTANCE;
- }
- return commandService.getEditCommand(req);
- }
-«ENDIF»
-'''
-
- /**
- * XXX for now, both constraints are injected into single method
- * which may not be suitable for modification especially when mixing
- * java and ocl constraints (former requires manual code).
- * Better approach would be:
- * if either is non-null and providers are not the same - introduce two methods,
- * to check source and target separately. Otherwize, do it inplace.
-*/
- override canExist(GenLink it) '''
- «generatedMemberComment()»
- public boolean canExist«stringUniqueIdentifier()»(
- «IF !it.sansDomain»
- «canExistParameters(it.modelFacet)»
- «ENDIF»
- ) {
- «IF creationConstraints != null && creationConstraints.isValid() && it.diagram.editorGen.expressionProviders != null»
- try {
- «IF creationConstraints.sourceEnd != null»
- «checkAdditionalConstraint(creationConstraints.sourceEnd.provider, creationConstraints.sourceEnd, 'source', 'target', creationConstraints.getSourceEndContextClass(), creationConstraints.getTargetEndContextClass())»
- «ENDIF»
- «IF creationConstraints.targetEnd != null»
- «checkAdditionalConstraint(creationConstraints.targetEnd.provider, creationConstraints.targetEnd, 'target', 'source', creationConstraints.getTargetEndContextClass(), creationConstraints.getSourceEndContextClass())»
- «ENDIF»
- return true;
- } catch(Exception e) {
- «xptPluginActivator.instanceAccess(it.diagram.editorGen)».logError("Link constraint evaluation error", e); «nonNLS()»
- return false;
- }
- «ELSE»
- return true;
- «ENDIF»
- }
- '''
-
- override def getGEFWrapper(GenDiagram it) '''
- «generatedMemberComment()»
- protected final org.eclipse.gef.commands.Command getGEFWrapper(org.eclipse.gmf.runtime.common.core.command.ICommand cmd) {
- return (cmd == null) ? org.eclipse.gef.commands.UnexecutableCommand.INSTANCE : new org.eclipse.gmf.runtime.diagram.ui.commands.ICommandProxy(cmd);
- }
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/CompartmentItemSemanticEditPolicy.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/CompartmentItemSemanticEditPolicy.xtend
deleted file mode 100644
index 846bc041d6e..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/CompartmentItemSemanticEditPolicy.xtend
+++ /dev/null
@@ -1,130 +0,0 @@
-/**
- * Copyright (c) 2006-2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.emf.common.util.EList
-import org.eclipse.gmf.codegen.gmfgen.GenChildNode
-import org.eclipse.gmf.codegen.gmfgen.GenCompartment
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import org.eclipse.gmf.codegen.gmfgen.TypeModelFacet
-import org.eclipse.papyrus.papyrusgmfgenextension.ConstrainedByReferenceCompartmentItemSemanticEditPolicy
-import xpt.Common
-import xpt.diagram.editpolicies.childContainerCreateCommand
-
-@Singleton class CompartmentItemSemanticEditPolicy extends xpt.diagram.editpolicies.CompartmentItemSemanticEditPolicy {
- @Inject extension Common;
- @Inject extension MetaModel
-
- @Inject childContainerCreateCommand xptChildContainerCreateCommand;
- @Inject BaseItemSemanticEditPolicy xptBaseItemSemanticEditPolicy;
-
-
- override CompartmentItemSemanticEditPolicy(GenCompartment it) '''
- «copyright(getDiagram().editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment()»
- public class «className(it)» extends «xptBaseItemSemanticEditPolicy.qualifiedClassName(getDiagram())» {
-
- «_constructor(it)»
-
- «xptChildContainerCreateCommand.childContainerCreateCommand( it.childNodes)»
-
- «additions(it)»
-
- ««« Papyrus REM :
- ««« Test if this compartment edit policy should used a referenced constraint for the move command.
-
- «IF it.eResource.allContents.filter(typeof (ConstrainedByReferenceCompartmentItemSemanticEditPolicy)).filter[v | v.genView.contains(it)].size != 0»
- «getChildNodeReference(childNodes)»
-
- «isCorrectCompartment(it)»
-
- «constraintedMoveCommand(it)»
-
- «ENDIF»
- }
- '''
-
-def getChildNodeReference (EList<GenChildNode> it) '''
- «IF !(it.isEmpty)»
- «generatedMemberComment»
- private static Set<EReference> compartmentReferences;
-
- «generatedMemberComment»
- static {
- ««« compartmentReferences = new HashSet<EReference>(«it.modelFacet->size()»);
- compartmentReferences = new HashSet<EReference>();
-
- «FOR n : it»
- «childRef(n.modelFacet,n)»
- «ENDFOR»
- }
- «generatedMemberComment»
- protected Iterable<EReference> getCompartmentReferences() {
- return compartmentReferences;
- }
-«ENDIF»
-
-'''
-
-def childRef(TypeModelFacet it ,GenNode node) '''
- compartmentReferences.add(«MetaFeature (node.modelFacet.containmentMetaFeature)»);
-'''
-
-
-def isCorrectCompartment (GenCompartment it)'''
- «generatedMemberComment»
- protected boolean isMovedIntoCorrectCompartment(MoveRequest req){
- for(Object entry : req.getElementsToMove().entrySet()) {
- if(entry instanceof Map.Entry<?, ?>) {
- Map.Entry<?, ?> mapEntry = (Map.Entry<?, ?>)entry;
- Object key = mapEntry.getKey();
- if(key instanceof EObject) {
- EObject dropppedObject = (EObject)key;
- EObject semanticHost = ((IGraphicalEditPart)getHost()).resolveSemanticElement();
- boolean foundERefrences = false;
- if(semanticHost != null) {
- for(EReference ref : getCompartmentReferences()) {
- if(ref.isContainment()) {
- foundERefrences = PackageUtil.canContain(semanticHost.eClass(), ref, dropppedObject.eClass(), false);
- } else {
- foundERefrences = PackageUtil.canReference(semanticHost.eClass(), ref, dropppedObject.eClass());
- }
- if(foundERefrences) {
- return true;
- }
- }
- }
- }
- }
- }
- return false;
- }
-'''
-
-def constraintedMoveCommand (GenCompartment it)'''
- «generatedMemberComment»
- @Override
- protected Command getMoveCommand(MoveRequest req) {
- if (isMovedIntoCorrectCompartment(req)){
- return super.getMoveCommand(req);
- } else {
- return UnexecutableCommand.INSTANCE;
- }
- }
-'''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/DiagramItemSemanticEditPolicy.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/DiagramItemSemanticEditPolicy.xtend
deleted file mode 100644
index 70e7cd045fd..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/DiagramItemSemanticEditPolicy.xtend
+++ /dev/null
@@ -1,20 +0,0 @@
-/**
- * Copyright (c) 2006, 2009 Borland Software Corporation
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Singleton
-
-@Singleton class DiagramItemSemanticEditPolicy extends xpt.diagram.editpolicies.DiagramItemSemanticEditPolicy {
-
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/LinkItemSemanticEditPolicy.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/LinkItemSemanticEditPolicy.xtend
deleted file mode 100644
index 6e90c98ed11..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/LinkItemSemanticEditPolicy.xtend
+++ /dev/null
@@ -1,54 +0,0 @@
-/**
- * Copyright (c) 2007-2012 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Borland) - [243151] explicit source/target for links
- * - #386838 - migrate to Xtend2
- * Vincent Lorenzo (CEA-LIST)
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import impl.diagram.commands.DeleteLinkCommand
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.TypeLinkModelFacet
-import org.eclipse.papyrus.papyrusgmfgenextension.EditPartUsingDeleteService
-import utils.UtilsItemSemanticEditPolicy
-import xpt.Common
-
-@Singleton class LinkItemSemanticEditPolicy extends xpt.diagram.editpolicies.LinkItemSemanticEditPolicy {
- @Inject extension Common;
- @Inject extension DeleteLinkCommand
- @Inject extension UtilsItemSemanticEditPolicy
-
- override dispatch getDestroySemanticCommand(TypeLinkModelFacet it, GenLink genLink) '''
- ««« Test to know which delete command should be used in the generated code : "Traditional Delete Command" or the Delete Service
-
- «IF it.eResource.allContents.filter(typeof (EditPartUsingDeleteService)).filter[v | v.genView.contains(genLink)].size !=0 »
-
- «generatedMemberComment»
- «getDestroyElementCommandByService(it)»
- «ELSE»
- «generatedMemberComment»
- protected org.eclipse.gef.commands.Command getDestroyElementCommand(org.eclipse.gmf.runtime.emf.type.core.requests.DestroyElementRequest req) {
- org.eclipse.gmf.runtime.emf.commands.core.command.CompositeTransactionalCommand cmd = new org.eclipse.gmf.runtime.emf.commands.core.command.CompositeTransactionalCommand(getEditingDomain(), null);
- cmd.setTransactionNestingEnabled(true);
- java.util.List<org.eclipse.emf.ecore.EObject> todestroy=new java.util.ArrayList<org.eclipse.emf.ecore.EObject>();
- todestroy.add(req.getElementToDestroy());
- //cmd.add(new org.eclipse.gmf.runtime.emf.type.core.commands.DestroyElementCommand(req));
- cmd.add(new org.eclipse.papyrus.infra.emf.gmf.command.EMFtoGMFCommandWrapper(new org.eclipse.emf.edit.command.DeleteCommand(getEditingDomain(),todestroy )));
- return getGEFWrapper(cmd.reduce());
- //return getGEFWrapper(«newDeleteLinkWithClassCommand(it,genLink, 'req')»);
- }
- «ENDIF»
- '''
-
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/NodeItemSemanticEditPolicy.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/NodeItemSemanticEditPolicy.xtend
deleted file mode 100644
index 793aa38e235..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/NodeItemSemanticEditPolicy.xtend
+++ /dev/null
@@ -1,253 +0,0 @@
-/**
- * Copyright (c) 2007-2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Artem Tikhomirov (Borland) - [257632] do not rely on EditPart presence for element deletion
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import java.util.List
-import org.eclipse.gmf.codegen.gmfgen.FeatureLinkModelFacet
-import org.eclipse.gmf.codegen.gmfgen.GenChildNode
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import org.eclipse.gmf.codegen.gmfgen.TypeLinkModelFacet
-import org.eclipse.papyrus.papyrusgmfgenextension.EditPartUsingDeleteService
-import utils.UtilsItemSemanticEditPolicy
-import xpt.Common
-import xpt.diagram.editpolicies.childContainerCreateCommand
-import xpt.editor.VisualIDRegistry
-
-/**
- * This template should be called only for non-design nodes (modelFacet != null)
- * because *ItemSemanticEditPolicy responsible for dealing with semantic model
- * elements and meaningless (should not be generated) for pure design nodes.
- */
-@Singleton class NodeItemSemanticEditPolicy extends xpt.diagram.editpolicies.NodeItemSemanticEditPolicy {
-
- @Inject extension Common;
- @Inject extension xpt.diagram.editpolicies.Utils_qvto;
- @Inject extension UtilsItemSemanticEditPolicy
-
-
- @Inject BaseItemSemanticEditPolicy xptBaseItemSemanticEditPolicy;
- @Inject childContainerCreateCommand xptChildContainerCreateCommand;
- @Inject linkCommands xptLinkCommands;
- @Inject VisualIDRegistry xptVisualIDRegistry;
-
-
-
- override NodeItemSemanticEditPolicy(GenNode it) '''
- «copyright(getDiagram().editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment()»
- public class «className(it)» extends «xptBaseItemSemanticEditPolicy.qualifiedClassName(getDiagram())» {
-
- «xptBaseItemSemanticEditPolicy.defaultConstructor(it)»
-
- «xptChildContainerCreateCommand.childContainerCreateCommand(it.childNodes)»
-
- ««« Papyrus REM :
- ««« Test to know how the delete of this EditPart is done : we used the DeleteService or the "Traditional method"
-
- «IF it.eResource.allContents.filter(typeof (EditPartUsingDeleteService)).filter[v | v.genView.contains(it)].size != 0»
- «generatedMemberComment»
- «getDestroyElementCommandByService(it)»
- «ELSE»
- «getDestroyElementCommand(it)»
- «IF hasChildrenOrCompartments(it)»
- «addDestroyChildNodesCommand(it)»
- «ENDIF»
- «ENDIF»
-
- «xptLinkCommands.linkCommands(it)»
-
- «additions(it)»
- }
- '''
-
- override getDestroyElementCommand(GenNode it) '''
- «generatedMemberComment()»
-protected org.eclipse.gef.commands.Command getDestroyElementCommand(org.eclipse.gmf.runtime.emf.type.core.requests.DestroyElementRequest req) {
- org.eclipse.gmf.runtime.notation.View view = (org.eclipse.gmf.runtime.notation.View) getHost().getModel();
- org.eclipse.gmf.runtime.emf.commands.core.command.CompositeTransactionalCommand cmd = new org.eclipse.gmf.runtime.emf.commands.core.command.CompositeTransactionalCommand(getEditingDomain(), null);
- cmd.setTransactionNestingEnabled(true);
- ««« «destroyEdges('view')»
- org.eclipse.emf.ecore.EAnnotation annotation = view.getEAnnotation("Shortcut");«nonNLS»
- if (annotation == null) {
- // there are indirectly referenced children, need extra commands: «it.childNodes.union(compartments.map(c | c.childNodes).flatten).exists[GenChildNode gcn | !isDirectlyOwned(gcn, it)]»
- «IF hasChildrenOrCompartments(it)»
- addDestroyChildNodesCommand(cmd);
- «ENDIF»
- addDestroyShortcutsCommand(cmd, view);
- // delete host element
- java.util.List<org.eclipse.emf.ecore.EObject> todestroy=new java.util.ArrayList<org.eclipse.emf.ecore.EObject>();
- todestroy.add(req.getElementToDestroy());
- //cmd.add(new org.eclipse.gmf.runtime.emf.type.core.commands.DestroyElementCommand(req));
- cmd.add(new org.eclipse.papyrus.infra.emf.gmf.command.EMFtoGMFCommandWrapper(new org.eclipse.emf.edit.command.DeleteCommand(getEditingDomain(),todestroy )));
- } else {«««Here, we may play smart and don't generate else for non-toplevel nodes(which can't be shortcuts). Is it worth doing?
- cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), view));
- }
- return getGEFWrapper(cmd.reduce());
-}
- '''
-
- override addDestroyChildNodesCommand(GenNode it) '''
- «generatedMemberComment()»
- protected void addDestroyChildNodesCommand(org.eclipse.gmf.runtime.common.core.command.ICompositeCommand cmd) {
- org.eclipse.gmf.runtime.notation.View view = (org.eclipse.gmf.runtime.notation.View) getHost().getModel();
- for (java.util.Iterator<?> nit = view.getChildren().iterator(); nit.hasNext();) {
- org.eclipse.gmf.runtime.notation.Node node = (org.eclipse.gmf.runtime.notation.Node) nit.next();
- String vid = «xptVisualIDRegistry.getVisualIDMethodCall(it.diagram)»(node);
- if (vid != null) {
- switch (vid) {
- «FOR cn : it.childNodes»
- «destroyChildNodes(cn, 'node', it)»
- «ENDFOR»
- «FOR compartment : it.compartments»
- «xptVisualIDRegistry.caseVisualID(compartment)»
- for (java.util.Iterator<?> cit = node.getChildren().iterator(); cit.hasNext();) {
- org.eclipse.gmf.runtime.notation.Node cnode = (org.eclipse.gmf.runtime.notation.Node) cit.next();
- String cvid = «xptVisualIDRegistry.getVisualIDMethodCall(it.diagram)»(cnode);
- if (cvid != null) {
- switch (cvid) {
- «FOR cn : compartment.childNodes»
- «destroyChildNodes(cn, 'cnode', it)»
- «ENDFOR»
- }
- }
- }
- break;
- «ENDFOR»
- }
- }
- }
- }
- '''
-
-
- /**
- * @param view - Notation element for the passed node
- * assumes 'cmd' to point to composite command
- */
- override destroyEdges(GenNode it, String view) '''
-
-««« XXX: Though semantic editpolicy is supposed to create commands that operate with semantic elements only,
-««« old code used to delegate child/link deletion to respective editparts, which in turn led to semantic commands
-««« being combined with notational commands (BaseItemSemanticEditPolicy#addDeleteViewCommand()).
-««« ---
-««« Use DiagramUpdater.get[Incoming|Outgoing]View instead, to clean links that are not present on a diagram
-««« (but don't forget to clean corresponding Edge, if any)
-
-
-«««// This part is commented for Papyrus
-«««// Some Papyrus diagrams with lots of elements are reaching the 65K Java limit for method size.
-«««// The following change is not supposed to modify the method behavior, just propose a slight more
-«««// compact code to avoid size limit.
-«««
-««««IF genIncomingLinks->notEmpty()-»
-««« for («EXPAND CodeStyle::G('java.util.Iterator', '?' /*FIXME Refactor once Notation model is Java5*/)» it = «view».getTargetEdges().iterator(); it.hasNext();) {
-««« org.eclipse.gmf.runtime.notation.Edge incomingLink = (org.eclipse.gmf.runtime.notation.Edge) it.next();
-««««FOREACH genIncomingLinks AS il-»
-««« if («EXPAND xpt::editor::VisualIDRegistry::getVisualIDMethodCall FOR getDiagram()»(incomingLink) == «EXPAND xpt::editor::VisualIDRegistry::visualID FOR il») {
-««« «EXPAND impl::diagram::commands::DeleteLinkCommand::newRequest('r', 'incomingLink') FOR il-»
-««« cmd.add(«EXPAND impl::diagram::commands::DeleteLinkCommand::newInstance('r') FOR il»);
-««« cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), incomingLink));
-««« continue;
-««« }
-««««ENDFOREACH-»
-««« }
-««««ENDIF-»
-««««IF genOutgoingLinks->notEmpty()-»
-««« for («EXPAND CodeStyle::G('java.util.Iterator', '?' /*FIXME Refactor once Notation model is Java5*/)» it = «view».getSourceEdges().iterator(); it.hasNext();) {
-««« org.eclipse.gmf.runtime.notation.Edge outgoingLink = (org.eclipse.gmf.runtime.notation.Edge) it.next();
-««««FOREACH genOutgoingLinks AS ol-»
-««« if («EXPAND xpt::editor::VisualIDRegistry::getVisualIDMethodCall FOR getDiagram()»(outgoingLink) == «EXPAND xpt::editor::VisualIDRegistry::visualID FOR ol») {
-««« «EXPAND impl::diagram::commands::DeleteLinkCommand::newRequest('r', 'outgoingLink') FOR ol-»
-««« cmd.add(«EXPAND impl::diagram::commands::DeleteLinkCommand::newInstance('r') FOR ol»);
-««« cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), outgoingLink));
-««« continue;
-««« }
-««««ENDFOREACH-»
-««« }
-««««ENDIF-»
-
-
-«IF !genIncomingLinks.isEmpty()»
- for (java.util.Iterator<?> it = «view».getTargetEdges().iterator(); it.hasNext();) {
- org.eclipse.gmf.runtime.notation.Edge incomingLink = (org.eclipse.gmf.runtime.notation.Edge) it.next();
- String vid = «xptVisualIDRegistry.getVisualIDMethodCall(getDiagram())»(incomingLink);
- if (vid != null) {
- switch(vid) {
-«IF !genIncomingLinks.filter[l | l.modelFacet instanceof FeatureLinkModelFacet].empty»
-«FOR il : genIncomingLinks.filter[l | l.modelFacet instanceof FeatureLinkModelFacet]»
- case «VisualIDRegistry.visualID(il)»:
-«ENDFOR»
- org.eclipse.gmf.runtime.emf.type.core.requests.DestroyReferenceRequest destroyRefReq = new org.eclipse.gmf.runtime.emf.type.core.requests.DestroyReferenceRequest(incomingLink.getSource().getElement(), null, incomingLink.getTarget().getElement(), false);
- cmd.add(new org.eclipse.gmf.runtime.emf.type.core.commands.DestroyReferenceCommand(destroyRefReq));
- cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), incomingLink));
- break;
-«ENDIF»
-«IF !genIncomingLinks.filter[l | l.modelFacet instanceof TypeLinkModelFacet].empty»
-«FOR il : genIncomingLinks.filter[l | l.modelFacet instanceof TypeLinkModelFacet]»
- case «VisualIDRegistry.visualID(il)»:
-«ENDFOR»
- org.eclipse.gmf.runtime.emf.type.core.requests.DestroyElementRequest destroyEltReq = new org.eclipse.gmf.runtime.emf.type.core.requests.DestroyElementRequest(incomingLink.getElement(), false);
- cmd.add(new org.eclipse.gmf.runtime.emf.type.core.commands.DestroyElementCommand(destroyEltReq));
- cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), incomingLink));
- break;
-«ENDIF»
- }
- }
- }
-«ENDIF»
-
-«IF genOutgoingLinks.isEmpty()»
- for (java.util.Iterator<?> it = «view».getSourceEdges().iterator(); it.hasNext();) {
- org.eclipse.gmf.runtime.notation.Edge outgoingLink = (org.eclipse.gmf.runtime.notation.Edge) it.next();
- String vid = «xptVisualIDRegistry.getVisualIDMethodCall(getDiagram())»(outgoingLink);
- if (vid != null) {
- switch(vid) {
-«IF !genOutgoingLinks.filter[l | l.modelFacet instanceof FeatureLinkModelFacet].empty»
-«FOR ol : genOutgoingLinks.filter[l | l.modelFacet instanceof FeatureLinkModelFacet]»
- case «VisualIDRegistry.visualID(ol)»:
-«ENDFOR»
- org.eclipse.gmf.runtime.emf.type.core.requests.DestroyReferenceRequest destroyRefReq = new org.eclipse.gmf.runtime.emf.type.core.requests.DestroyReferenceRequest(outgoingLink.getSource().getElement(), null, outgoingLink.getTarget().getElement(), false);
- cmd.add(new org.eclipse.gmf.runtime.emf.type.core.commands.DestroyReferenceCommand(destroyRefReq));
- cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), outgoingLink));
- break;
-«ENDIF»
-«IF !genOutgoingLinks.filter[l | l.modelFacet instanceof TypeLinkModelFacet].empty»
-«FOR ol : genOutgoingLinks.filter[l | l.modelFacet instanceof TypeLinkModelFacet]»
- case «VisualIDRegistry.visualID(ol)»:
-«ENDFOR»
- org.eclipse.gmf.runtime.emf.type.core.requests.DestroyElementRequest destroyEltReq = new org.eclipse.gmf.runtime.emf.type.core.requests.DestroyElementRequest(outgoingLink.getElement(), false);
- cmd.add(new org.eclipse.gmf.runtime.emf.type.core.commands.DestroyElementCommand(destroyEltReq));
- cmd.add(new org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand(getEditingDomain(), outgoingLink));
- break;
-«ENDIF»
- }
- }
- }
-«ENDIF»
- '''
-
-
-
- private def static <T> Iterable<T> union(Iterable<? extends T> listA, Iterable<? extends T> listB) {
- var List<T> result = newLinkedList();
- result.addAll(listA);
- result.addAll(listB);
- return result;
- }
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/OpenDiagram.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/OpenDiagram.xtend
deleted file mode 100644
index a0fa5e6fdf1..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/OpenDiagram.xtend
+++ /dev/null
@@ -1,77 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Artem Tikhomirov (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.OpenDiagramBehaviour
-import xpt.Common
-import xpt.editor.DiagramEditorUtil
-
-@Singleton class OpenDiagram extends xpt.diagram.editpolicies.OpenDiagram {
- @Inject extension Common;
-
-
- @Inject DiagramEditorUtil xptDiagramEditorUtil;
-
-
-
- override openCommandClass_intializeNewDiagram(OpenDiagramBehaviour it) '''
- «generatedMemberComment»
- protected org.eclipse.gmf.runtime.notation.Diagram intializeNewDiagram() throws org.eclipse.core.commands.ExecutionException {
- org.eclipse.gmf.runtime.notation.Diagram d = org.eclipse.gmf.runtime.diagram.core.services.ViewService.createDiagram(getDiagramDomainElement(), getDiagramKind(), getPreferencesHint());
- if (d == null) {
- throw new org.eclipse.core.commands.ExecutionException("Can't create diagram of '" + getDiagramKind() + "' kind");
- }
- diagramFacet.setDiagramLink(d);
- «_assert('diagramFacet.eResource() != null')»
- diagramFacet.eResource().getContents().add(d);
- org.eclipse.emf.ecore.EObject container = diagramFacet.eContainer();
- while (container instanceof org.eclipse.gmf.runtime.notation.View) {
- ((org.eclipse.gmf.runtime.notation.View) container).persist();
- container = container.eContainer();
- }
- try {
- «IF null == subject.diagram.editorGen.application»
- new org.eclipse.ui.actions.WorkspaceModifyOperation() {
- protected void execute(org.eclipse.core.runtime.IProgressMonitor monitor) throws org.eclipse.core.runtime.CoreException, java.lang.reflect.InvocationTargetException, InterruptedException {
- try {
- «ENDIF»
- for (java.util.Iterator<?> it = diagramFacet.eResource().getResourceSet().getResources().iterator(); it.hasNext();) {
- org.eclipse.emf.ecore.resource.Resource nextResource = (org.eclipse.emf.ecore.resource.Resource) it.next();
- if (nextResource.isLoaded() && !getEditingDomain().isReadOnly(nextResource)) {
- nextResource.save(«xptDiagramEditorUtil.qualifiedClassName(subject.diagram)».getSaveOptions());
- }
- }
- «IF null == subject.diagram.editorGen.application»
- } catch (java.io.IOException ex) {
- throw new java.lang.reflect.InvocationTargetException(ex, "Save operation failed");
- }
- }
- }.run(null);
- } catch (java.lang.reflect.InvocationTargetException e) {
- throw new org.eclipse.core.commands.ExecutionException("Can't create diagram of '" + getDiagramKind() + "' kind", e);
- } catch (InterruptedException e) {
- throw new org.eclipse.core.commands.ExecutionException("Can't create diagram of '" + getDiagramKind() + "' kind", e);
- }
- «ELSE»
- } catch (java.io.IOException ex) {
- throw new org.eclipse.core.commands.ExecutionException("Can't create diagram of '" + getDiagramKind() + "' kind", ex);
- }
- «ENDIF»
- return d;
- }
- '''
-
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextNonResizableEditPolicy.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextNonResizableEditPolicy.xtend
deleted file mode 100644
index 2487fbd04ec..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextNonResizableEditPolicy.xtend
+++ /dev/null
@@ -1,39 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 CEA LIST and other.
- *
- * 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:
- * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - #510281 change dependency to replace gmft-runtime
- *****************************************************************************/
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Common
-
-/**
- * FIXME: [MG] - reverse the calls? call common code from here and TextelectionEP and not vice versa
-*/
-@Singleton class TextNonResizableEditPolicy extends xpt.diagram.editpolicies.TextNonResizableEditPolicy {
-
- @Inject extension Common;
-
- override TextNonResizableEditPolicy_implementsClause(GenDiagram it) '''implements org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.edit.policies.labels.IRefreshableFeedbackEditPolicy'''
-
- override def TextNonResizableEditPolicy_createSelectionHandles(GenDiagram it) '''
- «generatedMemberComment»
- protected java.util.List<?> createSelectionHandles() {
- org.eclipse.gef.handles.MoveHandle moveHandle =
- new org.eclipse.gef.handles.MoveHandle((org.eclipse.gef.GraphicalEditPart) getHost());
- moveHandle.setBorder(null);
- moveHandle.setDragTracker(new org.eclipse.gmf.runtime.diagram.ui.tools.DragEditPartsTrackerEx(getHost()));
- return java.util.Collections.singletonList(moveHandle);
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextSelectionEditPolicy.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextSelectionEditPolicy.xtend
deleted file mode 100644
index f9eeda69216..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/TextSelectionEditPolicy.xtend
+++ /dev/null
@@ -1,56 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 CEA LIST and other.
- *
- * 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:
- * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - #510281 change dependency to replace gmft-runtime
- *****************************************************************************/
-package aspects.xpt.diagram.editpolicies
-
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import com.google.inject.Inject
-import xpt.Common
-import com.google.inject.Singleton
-import xpt.CodeStyle
-
-@Singleton class TextSelectionEditPolicy extends xpt.diagram.editpolicies.TextSelectionEditPolicy {
-
- @Inject extension Common
- @Inject extension CodeStyle
-
- // rebranch to the tooling runtime in the release train.
- override TextSelectionEditPolicy_implementsClause(GenDiagram it) '''implements org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.edit.policies.labels.IRefreshableFeedbackEditPolicy'''
-
- override textFeedback_createFocusFeedbackFigure(GenDiagram it) '''
- «generatedMemberComment»
- protected org.eclipse.draw2d.IFigure createFocusFeedbackFigure() {
- return new org.eclipse.draw2d.Figure() {
-
- «overrideC»
- protected void paintFigure(org.eclipse.draw2d.Graphics graphics) {
- graphics.drawFocus(getBounds().getResized(-1, -1));
- }
- };
- }
- '''
-
- override textFeedback_getHostPositionListener(GenDiagram it) '''
- «generatedMemberComment»
- private org.eclipse.draw2d.FigureListener getHostPositionListener() {
- if (hostPositionListener == null) {
- hostPositionListener = new org.eclipse.draw2d.FigureListener() {
- «overrideI»
- public void figureMoved(org.eclipse.draw2d.IFigure source) {
- refreshFeedback();
- }
- };
- }
- return hostPositionListener;
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/Utils_qvto.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/Utils_qvto.xtend
deleted file mode 100644
index 4eb215bd4d6..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/Utils_qvto.xtend
+++ /dev/null
@@ -1,42 +0,0 @@
-/**
- * Copyright (c) 2007-2013 Borland Software Corporation && others
- *
- * All rights reserved. This program && the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, && is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Alexander Shatalin (Borland) - initial API && implementation
- * Michael Golubev (Borland) - [243151] explicit source/target for links
- * - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenLinkEnd
-
-@Singleton class Utils_qvto extends xpt.diagram.editpolicies.Utils_qvto {
-
-def Boolean containsCreateStartLinkCommand(GenLinkEnd it){
- for (l : getAllPotentialLinks(it)){
- if(createStartLinkCommand(l, it)){
- return true;
- }
- }
-
- return false;
-}
-
-def Boolean containsCreateCompleteLinkCommand(GenLinkEnd it){
- for (l : getAllPotentialLinks(it)){
- if(createCompleteLinkCommand(l, it)){
- return true;
- }
- }
-
- return false;
-}
-
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/childContainerCreateCommand.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/childContainerCreateCommand.xtend
deleted file mode 100644
index b6edf38f735..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/childContainerCreateCommand.xtend
+++ /dev/null
@@ -1,71 +0,0 @@
-/**
- * Copyright (c) 2007, 2009 Borland Software Corporation
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import org.eclipse.gmf.codegen.gmfgen.TypeModelFacet
-import org.eclipse.papyrus.papyrusgmfgenextension.GenerateUsingElementTypeCreationCommand
-import xpt.Common
-import xpt.providers.ElementTypes
-
-@Singleton class childContainerCreateCommand extends xpt.diagram.editpolicies.childContainerCreateCommand{
-
- @Inject extension Common;
-
- @Inject extension ElementTypes;
-
- @Inject extension MetaModel;
-
-
- override CharSequence childContainerCreateCommand(Iterable<? extends GenNode> nodes) '''
- «IF ! nodes.empty»
-
- «generatedMemberComment()»
- protected org.eclipse.gef.commands.Command getCreateCommand(org.eclipse.gmf.runtime.emf.type.core.requests.CreateElementRequest req) {
- org.eclipse.gmf.runtime.emf.type.core.IElementType requestElementType = req.getElementType();
- if(requestElementType == null) {
- return super.getCreateCommand(req);
- }
-
-
- «FOR n : nodes»
- «IF !n.sansDomain»
- «childNodeCreateCommand(n.modelFacet, n)»
- «ENDIF»
- «ENDFOR»
- return super.getCreateCommand(req);
- }
- «ENDIF»
- '''
-
- def childNodeCreateCommand(TypeModelFacet it,GenNode node)'''
- if («accessElementType(node)» == requestElementType) {
- «IF it.eResource.allContents.filter(typeof (GenerateUsingElementTypeCreationCommand)).size>0»
- // adjust the containment feature
- org.eclipse.emf.ecore.EReference containmentFeature = «MetaFeature(it.childMetaFeature)»;
- req.setContainmentFeature(containmentFeature);
- «ENDIF»
-
- «IF it.eResource.allContents.filter(typeof (GenerateUsingElementTypeCreationCommand)).size>0»
- return getGEFWrapper(getSemanticCreationCommand(req));
- «ELSE»
- return getGEFWrapper(new «node.getCreateCommandQualifiedClassName()»(req, org.eclipse.papyrus.infra.gmfdiag.common.utils.DiagramUtils.getDiagramFrom(getHost())));
- «ENDIF»
-
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/linkCommands.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/linkCommands.xtend
deleted file mode 100644
index 0b053d973f3..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/editpolicies/linkCommands.xtend
+++ /dev/null
@@ -1,194 +0,0 @@
-/**
- * Copyright (c) 2007-2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Dmitry Stadnik (Borland) - creation logic was moved in commands
- * Michael Golubev (Borland) - [243151] explicit source/target for links
- * - #386838 - migrate to Xtend2
- * Vincent Lorenzo (CEA LIST) vincent.lorenzo@cea.fr - Initial API and implementation
- */
-package aspects.xpt.diagram.editpolicies
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.GenLinkEnd
-import org.eclipse.papyrus.papyrusgmfgenextension.EditPartUsingReorientService
-import org.eclipse.papyrus.papyrusgmfgenextension.GenerateUsingElementTypeCreationCommand
-import xpt.Common
-import xpt.diagram.commands.CreateLinkCommand
-import xpt.diagram.editpolicies.Utils_qvto
-import xpt.editor.VisualIDRegistry
-import xpt.providers.ElementTypes
-
-/**
- * Start start of link creation.
- * User click to this editpart and start dragging with link tool.
- * Complete end of the command
- * User points to this editpart as a link target and release mouse button.
- *
- * Outgoing the node is link source
- * This element could be a source for this type of link.
- * Incoming the node is link destination
- * This element could be a target for this type of link.
- *
- * Parameters:
- *
- * diagram GenDiagram used to collect all defined links
- *
- * this Instance of GenLinkEnd for the element link could be creates to/from.
- * This could be GenNode or GenLink in case of links to links,
- * in the latter case it is assumed that its a TypeLink (so its model facet is LinkTypeModelFacet),
- * because RefLinks don't have underlying semantic identity
- *
-*/
-@Singleton class linkCommands extends xpt.diagram.editpolicies.linkCommands {
- @Inject extension Utils_qvto;
- @Inject extension Common;
-
- @Inject aspects.xpt.diagram.editpolicies.Utils_qvto aspectsUtils_qvto
- @Inject VisualIDRegistry xptVisualIDRegistry;
- @Inject ElementTypes xptElementTypes;
- @Inject CreateLinkCommand xptCreateLinkCommand;
-
- override createLinkCommands(GenLinkEnd it) '''
-
- «IF it.eResource.allContents.filter(typeof (GenerateUsingElementTypeCreationCommand)).size <1»
-
- «generatedMemberComment()»
- protected org.eclipse.gef.commands.Command getCreateRelationshipCommand(
- org.eclipse.gmf.runtime.emf.type.core.requests.CreateRelationshipRequest req) {
- org.eclipse.gef.commands.Command command = req.getTarget() == null ?
- getStartCreateRelationshipCommand(req) : getCompleteCreateRelationshipCommand(req);
- return command != null ? command : super.getCreateRelationshipCommand(req);
- }
- «ENDIF»
-
- «generatedMemberComment()»
- protected org.eclipse.gef.commands.Command getStartCreateRelationshipCommand(
- org.eclipse.gmf.runtime.emf.type.core.requests.CreateRelationshipRequest req) {
- org.eclipse.gmf.runtime.emf.type.core.IElementType requestElementType = req.getElementType();
- if(requestElementType == null) {
- return null;
- }
- org.eclipse.gmf.runtime.emf.type.core.IElementType baseElementType = requestElementType;
-
- «FOR l : getAllPotentialLinks(it)»
- «startLinkCommands(l, it)»
- «ENDFOR»
- return null;
- }
-
- «generatedMemberComment()»
- protected org.eclipse.gef.commands.Command getCompleteCreateRelationshipCommand(
- org.eclipse.gmf.runtime.emf.type.core.requests.CreateRelationshipRequest req) {
- org.eclipse.gmf.runtime.emf.type.core.IElementType requestElementType = req.getElementType();
- if(requestElementType == null) {
- return null;
- }
- org.eclipse.gmf.runtime.emf.type.core.IElementType baseElementType = requestElementType;
-
- «FOR l : getAllPotentialLinks(it)»
- «completeLinkCommands(l, it)»
- «ENDFOR»
- return null;
- }
- '''
-
- override startLinkCommands(GenLink it, GenLinkEnd linkEnd) '''
- if («xptElementTypes.accessElementType(it)» == baseElementType) {
- «IF createStartLinkCommand(it, linkEnd)»
-
- return getGEFWrapper(new «xptCreateLinkCommand.qualifiedClassName(it)»(req,
- «IF createStartIncomingLinkCommand(it, linkEnd)»
- req.getTarget(), req.getSource()
- «ELSE»
- req.getSource(), req.getTarget()
- «ENDIF»
- ));
- «ELSE»
- return null;
- «ENDIF»
- '''
-
- override completeLinkCommands(GenLink it, GenLinkEnd linkEnd) '''
- if («xptElementTypes.accessElementType(it)» == baseElementType) {
- «IF createCompleteLinkCommand(it, linkEnd)»
-
- return getGEFWrapper(new «xptCreateLinkCommand.qualifiedClassName(it)»(req,
- «IF createCompleteOutgoingLinkCommand(it, linkEnd)»
- req.getTarget(), req.getSource()
- «ELSE»
- req.getSource(), req.getTarget()
- «ENDIF»
- ));
- «ELSE»
- return null;
- «ENDIF»
- '''
-
-
- // We overwrite the reorientTypeLinkCommands to manages the links which use the ReorientCommand provided by the EditService
- override reorientTypeLinkCommands(GenLinkEnd it) '''
- «generatedMemberComment(
- 'Returns command to reorient EClass based link. New link target or source\n' + 'should be the domain model element associated with this node.\n'
- )»
- protected org.eclipse.gef.commands.Command getReorientRelationshipCommand(
- org.eclipse.gmf.runtime.emf.type.core.requests.ReorientRelationshipRequest req) {
- String vid = getVisualID(req);
- if (vid != null) {
- switch (vid) {
- «FOR link : getReroutableTypeLinks(it)»
- «reorientLinkCommandWithService(link) »
- «ENDFOR»
- «callReorientCommand(it)»
- «FOR link : getReroutableTypeLinks(it)»
- «reorientLinkCommandWithoutService(link) »
- «ENDFOR»
- }
- }
- return super.getReorientRelationshipCommand(req);
- }
- '''
-
- //This function writes only : "case myLinkEditPart.VISUAL_ID:"
- //for the link which uses the ReorientCommand provided by the EditService
- def reorientLinkCommandWithService(GenLink it) '''
- «IF it.eResource.allContents.filter(typeof(EditPartUsingReorientService)).filter[v| v.genView.contains(it)].size != 0»
- «xptVisualIDRegistry.caseVisualID(it)»
- «ENDIF»
- '''
-
- // This function writes the code to call the ReorientCommand provided by the ReorientService
- def callReorientCommand(GenLinkEnd it) '''
- «var rServiceNodes = it.eResource.allContents.filter(typeof (EditPartUsingReorientService))»
- «IF !rServiceNodes.empty»
- «IF !rServiceNodes.filter[rServiceNode|(!(rServiceNode.genView.filter[view|getReroutableTypeLinks(it).toList.contains(view)].empty))].empty»
- org.eclipse.papyrus.infra.services.edit.service.IElementEditService provider =org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils.getCommandProvider(req.getRelationship());
- if(provider == null) {
- return org.eclipse.gef.commands.UnexecutableCommand.INSTANCE;
- }
- // Retrieve re-orient command from the Element Edit service
- org.eclipse.gmf.runtime.common.core.command.ICommand reorientCommand = provider.getEditCommand(req);
- if(reorientCommand == null) {
- return org.eclipse.gef.commands.UnexecutableCommand.INSTANCE;
- }
- return getGEFWrapper(reorientCommand.reduce());
- «ENDIF»
- «ENDIF»
- '''
-
- // This function writes the code for the Links which uses their own ReorientCommand (the initial code)
- def reorientLinkCommandWithoutService(GenLink it) '''
- «IF it.eResource.allContents.filter(EditPartUsingReorientService).filter[v|v.genView.contains(it)].size == 0»
- «reorientLinkCommand(it)»
- «ENDIF»
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/PreferenceInitializer.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/PreferenceInitializer.xtend
deleted file mode 100644
index fcfd307dae9..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/PreferenceInitializer.xtend
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * Copyright (c) 2007, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Thibault Landre (Atos Origin) - initial API and implementation
- * Patrick Tessier (CEA LIST)
- */
-package aspects.xpt.diagram.preferences
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import plugin.Activator
-import xpt.Common
-
-@Singleton class PreferenceInitializer extends xpt.diagram.preferences.PreferenceInitializer {
- @Inject extension Common;
-
- @Inject Activator xptActivator;
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/extensions.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/extensions.xtend
deleted file mode 100644
index 0e890118934..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/preferences/extensions.xtend
+++ /dev/null
@@ -1,70 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Thibault Landre (Atos Origin) - initial API and implementation
- */
-package aspects.xpt.diagram.preferences
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import org.eclipse.gmf.codegen.gmfgen.GenStandardPreferencePage
-import org.eclipse.gmf.codegen.gmfgen.StandardPreferencePages
-import utils.PrefsConstant_qvto
-import xpt.Common
-import xpt.diagram.Utils_qvto
-
-@Singleton class extensions extends xpt.diagram.preferences.extensions {
- @Inject extension Common;
- @Inject extension Utils_qvto;
- @Inject extension PrefsConstant_qvto;
-
- @Inject xpt.diagram.preferences.PreferenceInitializer xptPreferenceInitializer;
-
- override extensions(GenDiagram it) '''
-
- «tripleSpace(1)»<extension point="org.eclipse.core.runtime.preferences" id="prefs">
- «tripleSpace(2)»«xmlGeneratedTag»
- «tripleSpace(2)»<initializer class="«xptPreferenceInitializer.qualifiedClassName(it)»"/>
- «tripleSpace(1)»</extension>
-
- «IF ! it.preferencePages.empty»
- «tripleSpace(1)»<extension point="org.eclipse.ui.preferencePages" id="prefpages">
- «tripleSpace(2)»«xmlGeneratedTag»
- «FOR pref : allPreferencePages(it)»
- «IF pref instanceof GenStandardPreferencePage»
- «papyrusPreferencePage(pref as GenStandardPreferencePage)»
- «ENDIF»
- «ENDFOR»
- «tripleSpace(1)»</extension>
- «ENDIF»
- '''
-
- def papyrusPreferencePage(GenStandardPreferencePage it) '''
- «IF StandardPreferencePages.GENERAL_LITERAL == kind»
- <page
- id="«getDiagramPreferencePageCategory()».«getDiagram().editorGen.modelID»"
- name="«getDiagram().editorGen.modelID» Diagram"
- category="«getDiagramPreferencePageCategory()»"
- class="«getQualifiedClassName()»">
- </page>
- «ELSEIF StandardPreferencePages.PRINTING_LITERAL == kind ||
- StandardPreferencePages.RULERS_AND_GRID_LITERAL == kind»
- <page
- id="«getQualifiedClassName()»"
- name="%prefpage.«ID»"
- category="«getDiagramPreferencePageCategory()».«getDiagram().editorGen.modelID»"
- class="«getQualifiedClassName()»">
- </page>
- «ENDIF»
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/DiagramUpdater.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/DiagramUpdater.xtend
deleted file mode 100644
index 917f24898af..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/DiagramUpdater.xtend
+++ /dev/null
@@ -1,361 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2014 Borland Software Corporation, CEA, and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Borland) - [243151] explicit source/target for links
- * Michael Golubev (Montages) - API extracted to gmf.tooling.runtime, template migrated to Xtend2
- * Christian W. Damus (CEA) - bug 426732: override the cross-reference searches for views to use the CrossReferenceAdapter
- */
-package aspects.xpt.diagram.updater
-
-import aspects.xpt.Common
-import aspects.xpt.editor.VisualIDRegistry
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.gmf.codegen.gmfgen.FeatureLinkModelFacet
-import org.eclipse.gmf.codegen.gmfgen.GenCommonBase
-import org.eclipse.gmf.codegen.gmfgen.GenContainerBase
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import org.eclipse.gmf.codegen.gmfgen.GenDiagramUpdater
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.GenNode
-import org.eclipse.gmf.codegen.gmfgen.TypeLinkModelFacet
-import org.eclipse.papyrus.papyrusgmfgenextension.CustomDiagramUpdaterSingleton
-import org.eclipse.papyrus.papyrusgmfgenextension.SpecificDiagramUpdater
-import xpt.Common_qvto
-import xpt.GenModelUtils_qvto
-import xpt.diagram.updater.UpdaterLinkType
-import xpt.diagram.updater.Utils_qvto
-import java.util.Set
-import org.eclipse.emf.codegen.ecore.genmodel.GenFeature
-
-// we removed all static modifiers and all private methods becames protected to allow to override method.
-//see bug421212: [Diagram] Papyrus should provide actions for Show/Hide related links in all diagrams
-@Singleton class DiagramUpdater extends xpt.diagram.updater.DiagramUpdater {
- @Inject extension Common;
- @Inject extension Common_qvto;
- @Inject extension Utils_qvto;
- @Inject extension GenModelUtils_qvto;
- @Inject xpt.diagram.updater.LinkDescriptor linkDescriptor;
- @Inject VisualIDRegistry xptVisualIDRegistry;
- @Inject xpt.diagram.updater.NodeDescriptor nodeDescriptor;
-
- @Inject MetaModel xptMetaModel;
-
- def diagramUpdaterInstanceToUse(GenDiagramUpdater it) '''
- «IF it.eResource.allContents.filter(typeof(CustomDiagramUpdaterSingleton)).filter[v|v.singletonPath != null].size ==
- 1»
- «it.eResource.allContents.filter(typeof(CustomDiagramUpdaterSingleton)).filter[v|v.singletonPath != null].head.
- singletonPath»
- «ELSE»
- «diagramUpdaterQualifiedClassName».INSTANCE
- «ENDIF»
- '''
-
- protected def typeOfCrossReferenceAdapter() '''org.eclipse.gmf.runtime.emf.core.util.CrossReferenceAdapter'''
-
- override getSemanticChildrenMethodCall(GenContainerBase it) '''«diagramUpdaterInstanceToUse(it.diagramUpdater)».«getSemanticChildrenMethodName(
- it)»'''
-
- override doGetSomeLinksMethodCall(GenCommonBase it, UpdaterLinkType linkType) '''«diagramUpdaterInstanceToUse(
- it.getDiagram().diagramUpdater)».«linkGetterName(linkType)»'''
-
- // override runtimeTypedInstanceName(GenDiagramUpdater it) '''INSTANCE'''
- //
- // override runtimeTypedInstanceCall(GenDiagramUpdater it) '''«qualifiedClassName(it)».«runtimeTypedInstanceName(it)»'''
- //protected constructor to allow overriding
- def _constructor(GenDiagramUpdater it) '''
- «generatedMemberComment()»
- protected «diagramUpdaterClassName»(){
- //to prevent instantiation allowing the override
- }
- '''
-
- //create the singleton using custom class defined in GMFGen
- public def classSingleton(GenDiagramUpdater it) '''
- «««we create the singleton only in the case where there is no custom diagram updater
- «IF it.eResource.allContents.filter(typeof(CustomDiagramUpdaterSingleton)).filter[v|v.singletonPath != null].size != 1»
- «generatedMemberComment()»
- public static final «diagramUpdaterQualifiedClassName» INSTANCE = new «diagramUpdaterClassName»();
- «ENDIF»
- '''
-
- override DiagramUpdater(GenDiagramUpdater it) '''
- «copyright(editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment»
- public class «className(it)» implements org.eclipse.papyrus.infra.gmfdiag.common.updater.DiagramUpdater {
- «classSingleton(it)»
- «_constructor(it)»
- «isShortcutOrphaned(it)»
- «var semanticContainers = it.editorGen.diagram.allContainers.filter[container|hasSemanticChildren(container)]»
- «getGenericSemanticChildrenOfView(it, semanticContainers)»
- «FOR next : semanticContainers»
- «getSemanticChildrenOfView(next)»
- «ENDFOR»
-
- «getPhantomNodesIterator(it)»
-
- «getGenericConnectedLinks(it, getAllSemanticElements(editorGen.diagram), UpdaterLinkType::CONTAINED)»
-
- «getGenericConnectedLinks(it, getAllSemanticDiagramElements(editorGen.diagram), UpdaterLinkType::INCOMING)»
-
- «getGenericConnectedLinks(it, getAllSemanticDiagramElements(editorGen.diagram), UpdaterLinkType::OUTGOING)»
- «FOR e : getAllSemanticElements(editorGen.diagram)»
- «getContainedLinks(e)»
- «ENDFOR»
- «FOR e : getAllSemanticDiagramElements(editorGen.diagram)»
- «getIncomingLinks(e)»
- «ENDFOR»
- «FOR e : getAllSemanticDiagramElements(editorGen.diagram)»
- «getOutgoingLinks(e)»
- «ENDFOR»
- «FOR link : getAllContainedLinks(editorGen.diagram)»
- «getContainedLinksByTypeMethod(link)»
- «ENDFOR»
- «FOR link : getAllIncomingLinks(editorGen.diagram)»
- «getIncomingLinksByTypeMethod(link)»
- «ENDFOR»
- «FOR link : getAllOutgoingLinks(editorGen.diagram)»
- «getOutgoingLinksByTypeMethod(link)»
- «ENDFOR»
-
- «runtimeTypedInstance(it)»
-
- «additions(it)»
- }
- '''
-
- override def getConnectedLinks(GenCommonBase it, Iterable<GenLink> genLinks, UpdaterLinkType linkType,
- boolean needCrossReferencer) '''
-
- «generatedMemberComment»
- «««remove static modifier
- public «listOfLinkDescriptors(it)» «linkGetterName(it, linkType)»(org.eclipse.gmf.runtime.notation.View view) {
- «IF genLinks.notEmpty»
- «xptMetaModel.DeclareAndAssign(it.metaClass, 'modelElement', 'view.getElement()')»
- «IF needCrossReferencer»
- «typeOfCrossReferenceAdapter» crossReferencer = «typeOfCrossReferenceAdapter».getCrossReferenceAdapter(view.eResource().getResourceSet());
- «ENDIF»
- «newLinkedListOfLinkDescriptors(it.diagramUpdater, 'result')»();
- «FOR link : genLinks»
- «colectConnectedLinks(link, linkType, needCrossReferencer, isExternalInterface(it.metaClass))»
- «ENDFOR»
- return result;
- «ELSE»
- return «newEmptyList()»;
- «ENDIF»
- }
- '''
-
- override def colectConnectedLinks(GenLink it, UpdaterLinkType linkType, boolean needCrossReferencer,
- boolean isExternalInterface) '''
- «IF it.modelFacet != null»
- «IF isExternalInterface && !it.modelFacet.oclIsKindOf(typeof(FeatureLinkModelFacet))»
- if («xptMetaModel.IsInstance(it.modelFacet.getLinkEndType(linkType), 'modelElement')») {
- «ENDIF»
- result.addAll(«chooseConnectedLinksByTypeMethodName(it.modelFacet, linkType, it)»(« //
- IF isExternalInterface && !it.modelFacet.oclIsKindOf(typeof(FeatureLinkModelFacet))»«xptMetaModel.
- CastEObject(it.modelFacet.getLinkEndType(linkType), 'modelElement')»«ELSE»modelElement«ENDIF»«IF needCrossReferencer», crossReferencer«ENDIF»));
- «IF isExternalInterface && !it.modelFacet.oclIsKindOf(typeof(FeatureLinkModelFacet))»
- }
- «ENDIF»
- «ENDIF»
- '''
-
- override def getIncomingLinksByTypeMethod(GenLink it) '''
- «generatedMemberComment»
- «««remove static modifier + private->protected
- protected java.util.Collection<«linkDescriptor.qualifiedClassName(it.diagramUpdater)»> «getConnectedLinksByTypeMethodName(
- UpdaterLinkType::INCOMING)»(«xptMetaModel.QualifiedClassName(it.modelFacet.targetType)» target, «typeOfCrossReferenceAdapter» crossReferencer) {
- «newLinkedListOfLinkDescriptors(it.diagramUpdater, 'result')»();
- java.util.Collection<org.eclipse.emf.ecore.EStructuralFeature.Setting> settings = crossReferencer.getInverseReferences(target);
- for (org.eclipse.emf.ecore.EStructuralFeature.Setting setting : settings) {
- «getIncomingLinksByTypeMethodBody(it.modelFacet, it)»
- }
- return result;
- }
- '''
-
- def CharSequence getICustomDiagramUpdater(GenContainerBase it) '''org.eclipse.papyrus.uml.diagram.common.part.ICustomDiagramUpdater<«nodeDescriptor.
- qualifiedClassName(it.diagramUpdater)»>'''
-
- override getSemanticChildrenOfView(GenContainerBase it) '''
- «««remove static modifier
- «IF it.eResource.allContents.filter(typeof(SpecificDiagramUpdater)).filter[v|v.genNode == it && v.classpath != null].
- size != 0»
- «generatedMemberComment»
- «FOR updater : it.eResource.allContents.filter(typeof(SpecificDiagramUpdater)).filter[v|
- v.genNode == it && v.classpath != null].toIterable»
- public «listOfNodeDescriptors» «getSemanticChildrenMethodName(it)»(org.eclipse.gmf.runtime.notation.View view) {
- «getICustomDiagramUpdater(it)» customUpdater = new «updater.classpath»();
- return customUpdater.getSemanticChildren(view);
- }
- «ENDFOR»
- «ELSE»
- «generatedMemberComment»
- public «listOfNodeDescriptors» «getSemanticChildrenMethodName(it)»(org.eclipse.gmf.runtime.notation.View view) {
- «IF getSemanticChildrenChildFeatures(it).notEmpty || it.getPhantomNodes().notEmpty»
- «defineModelElement(it)»
- «newLinkedListOfNodeDescriptors(it.diagramUpdater, 'result')»();
- «/* childMetaFeature can be null here! */FOR childMetaFeature : getSemanticChildrenChildFeatures(it)»
- «IF null == childMetaFeature»
- { /*FIXME no containment/child feature found in the genmodel, toolsmith need to specify Class here manually*/ childElement =
- /*FIXME no containment/child feature found in the genmodel, toolsmith need to specify correct one here manually*/;
- «ELSEIF childMetaFeature.listType»
- for (java.util.Iterator<?> it = «xptMetaModel.getFeatureValue(childMetaFeature, 'modelElement', it.getModelElementType())».iterator(); it.hasNext();) {
- «xptMetaModel.DeclareAndAssign(childMetaFeature.typeGenClass, 'childElement', 'it.next()', true)»
- «ELSE»
- { «xptMetaModel.DeclareAndAssign(childMetaFeature.typeGenClass, 'childElement', 'modelElement',
- it.getModelElementType(), childMetaFeature)»
- «ENDIF»
- String visualID = «xptVisualIDRegistry.getNodeVisualIDMethodCall(it.diagram)»(view, «xptMetaModel.
- DowncastToEObject(childMetaFeature.typeGenClass, 'childElement')»);
- «FOR next : getSemanticChildren(it, childMetaFeature)»
- «checkChildElementVisualID(next, null != childMetaFeature && childMetaFeature.listType)»
- «ENDFOR»
- }
- «ENDFOR»
- «IF it.getPhantomNodes.notEmpty»
- org.eclipse.emf.ecore.resource.Resource resource = modelElement.eResource();
- for (java.util.Iterator<org.eclipse.emf.ecore.EObject> it = getPhantomNodesIterator(resource); it.hasNext();) {
- org.eclipse.emf.ecore.EObject childElement = it.next();
- if (childElement == modelElement) {
- continue;
- }
- «FOR phantom : it.phantomNodes»
- «addNextIfPhantom(phantom)»
- «ENDFOR»
- }
- «ENDIF»
- return result;
- «ELSE»
- return «newEmptyList()»;
- «ENDIF»
- }
- «ENDIF»
- '''
-
-
- override defineLinkSource(TypeLinkModelFacet it, boolean inLoop) '''
- «IF sourceMetaFeature.listType»
- java.util.List<?> sources = «xptMetaModel.getFeatureValue(sourceMetaFeature, 'link', metaClass)»;
- Object theSource = sources.size() == 1 ? sources.get(0) : null;
- if («xptMetaModel.NotInstance(it.sourceType, 'theSource')») {
- «stopLinkProcessing(inLoop)»
- }
- «xptMetaModel.DeclareAndAssign(it.sourceType, 'src', 'theSource', true)»
- «ELSE»
- «xptMetaModel.DeclareAndAssign(it.sourceType, 'src', 'link', metaClass, sourceMetaFeature)»
- «ENDIF»
- '''
-
- def isDiagram(GenDiagram it) ''''''
-
- override defineLinkDestination(TypeLinkModelFacet it, Boolean inLoop) '''
- «IF targetMetaFeature.listType»
- java.util.List<?> targets = «xptMetaModel.getFeatureValue(it.targetMetaFeature, 'link', metaClass)»;
- Object theTarget = targets.size() == 1 ? targets.get(0) : null;
- if («xptMetaModel.NotInstance(it.targetType, 'theTarget')») {
- «stopLinkProcessing(inLoop)»
- }
- «xptMetaModel.DeclareAndAssign(it.targetType, 'dst', 'theTarget', true)»
- «ELSE»
- «xptMetaModel.DeclareAndAssign(it.targetType, 'dst', 'link', metaClass, targetMetaFeature)»
- «ENDIF»
- '''
-
- //remove static modifier + private->protected
- override getOutgoingLinksByTypeMethodSignature(GenLink it) '''protected java.util.Collection<«linkDescriptor.
- qualifiedClassName(it.diagramUpdater)»> «getConnectedLinksByTypeMethodName(UpdaterLinkType::OUTGOING)»(«xptMetaModel.
- QualifiedClassName(it.modelFacet.sourceType)» source)'''
-
- override getGenericSemanticChildrenOfView(GenDiagramUpdater it, Iterable<GenContainerBase> semanticContainers) '''
-
- «generatedMemberComment»
- ««« remove static modifier
- public «listOfNodeDescriptors» getSemanticChildren(org.eclipse.gmf.runtime.notation.View view) {
- «IF semanticContainers.notEmpty»
- String vid = «xptVisualIDRegistry.getVisualIDMethodCall(editorGen.diagram)»(view);
- if (vid != null) {
- switch (vid) {
- «FOR next : semanticContainers»
- «getSemanticChildrenCase(next)»
- «ENDFOR»
- }
- }
- «ENDIF»
- return «newEmptyList()»;
- }
- '''
-
- override dispatch getContainedLinksByTypeMethod(TypeLinkModelFacet it, GenLink genLink) '''
-
- «generatedMemberComment»
- ««« remove static modifier + private->protected
- protected java.util.Collection<«linkDescriptor.qualifiedClassName(genLink.diagramUpdater)»> «getConnectedLinksByTypeMethodName(
- genLink, UpdaterLinkType::CONTAINED)»(«xptMetaModel.QualifiedClassName(childMetaFeature.genClass)» container) {
- «getContainedLinksByTypeMethodBody(it, genLink, false)»
- }
- '''
-
- override getGenericConnectedLinks(GenDiagramUpdater it, Iterable<? extends GenCommonBase> linkContainers,
- UpdaterLinkType linkType) '''
-
- «generatedMemberComment»
- ««« remove static modifier
- public «listOfLinkDescriptors» get«linkType.linkMethodSuffix»Links(org.eclipse.gmf.runtime.notation.View view) {
- «IF linkContainers.notEmpty»
- String vid = «xptVisualIDRegistry.getVisualIDMethodCall(it.editorGen.diagram)»(view);
- if (vid != null) {
- switch (vid) {
- «FOR next : linkContainers»
- «getContainedLinksCase(next, linkType)»
- «ENDFOR»
- }
- }
- «ENDIF»
- return «newEmptyList»;
- }
- '''
-
- override runtimeTypedInstance(GenDiagramUpdater it) '''
- '''
-
- /**
- * XXX: [MG] suspicious code inside, EVEN after I moved ", " into the IF, there still may be problem if inner IF condition is not met.
- * Need to check with case when it.modelFacet.childMetaFeature == null
- */
- override def checkChildElementVisualID(GenNode it, Boolean inLoop) '''
- if («VisualIDRegistry::visualID(it)».equals(visualID)) {
- result.add(new «nodeDescriptor.qualifiedClassName(it.getDiagram().diagramUpdater)»(«IF null != modelFacet.childMetaFeature»«xptMetaModel.DowncastToEObject(modelFacet.childMetaFeature.typeGenClass, 'childElement')», «ENDIF»visualID));
- «IF inLoop»
- continue;
- «ENDIF»
- }
- '''
-
- override def checkLinkVisualID(TypeLinkModelFacet it, GenLink genLink, boolean inLoop) '''
- if (!«VisualIDRegistry::visualID(genLink)».equals(«xptVisualIDRegistry.getLinkWithClassVisualIDMethodCall(genLink.diagram)»(«xptMetaModel.DowncastToEObject(metaClass, 'link')»))) {
- «stopLinkProcessing(inLoop)»
- }
- '''
-
- override def getSemanticChildrenMethodName(GenContainerBase it) '''get«stringUniqueIdentifier()»_SemanticChildren'''
-
- override protected def linkGetterName(GenCommonBase it, UpdaterLinkType linkType) '''get«stringUniqueIdentifier()»_«linkType.linkMethodSuffix»Links'''
-
- override def getConnectedLinksByTypeMethodName(GenLink it, UpdaterLinkType linkType) '''get«linkType.linkMethodSuffix»«getConnectedLinksByTypeMethodFragment(modelFacet)»_«stringVisualID»'''
-
- override def dispatch getConnectedLinksByTypeMethodFragment(TypeLinkModelFacet it) '''TypeModelFacetLinks'''
-
- override def dispatch getConnectedLinksByTypeMethodFragment(FeatureLinkModelFacet it) '''FeatureModelFacetLinks'''
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/Extensions.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/Extensions.xtend
deleted file mode 100644
index a402f262ff2..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/Extensions.xtend
+++ /dev/null
@@ -1,24 +0,0 @@
-/**
- * Copyright (c) 2007, 2009 Borland Software Corporation
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Gabriel Pascual (ALL4TEC) - Bug 372322
- */
-package aspects.xpt.diagram.updater
-
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagramUpdater
-
-@Singleton class Extensions extends xpt.diagram.updater.extensions{
-
- override def extensions(GenDiagramUpdater it) {
- // Override Refresh contribution
- }
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/LinkDescriptor.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/LinkDescriptor.xtend
deleted file mode 100644
index d5ebb0ee871..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/LinkDescriptor.xtend
+++ /dev/null
@@ -1,41 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2014 Borland Software Corporation, CEA, and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Borland) - [243151] explicit source/target for links
- * Michael Golubev (Montages) - API extracted to gmf.tooling.runtime, template migrated to Xtend2
- * Christian W. Damus (CEA) - bug 426732: override the cross-reference searches for views to use the CrossReferenceAdapter
- */
-package aspects.xpt.diagram.updater
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagramUpdater
-import xpt.Common
-
-@Singleton class LinkDescriptor extends xpt.diagram.updater.LinkDescriptor {
- @Inject extension Common;
-
- override def extendsList(GenDiagramUpdater it) '''extends org.eclipse.papyrus.infra.gmfdiag.common.updater.UpdaterLinkDescriptor'''
-
- override def refOnlyLinkConstructor(GenDiagramUpdater it) '''
- «generatedMemberComment»
- public «className(it)»(org.eclipse.emf.ecore.EObject source, org.eclipse.emf.ecore.EObject destination, org.eclipse.gmf.runtime.emf.type.core.IElementType elementType, String linkVID) {
- super(source, destination, elementType, linkVID);
- }
- '''
-
- override def typeLinkConstructor(GenDiagramUpdater it) '''
- «generatedMemberComment»
- public «className(it)»(org.eclipse.emf.ecore.EObject source, org.eclipse.emf.ecore.EObject destination, org.eclipse.emf.ecore.EObject linkElement, org.eclipse.gmf.runtime.emf.type.core.IElementType elementType, String linkVID) {
- super(source, destination, linkElement, elementType, linkVID);
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/NodeDescriptor.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/NodeDescriptor.xtend
deleted file mode 100644
index 5dbb3e1e4ae..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/updater/NodeDescriptor.xtend
+++ /dev/null
@@ -1,34 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2014 Borland Software Corporation, CEA, and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Borland) - [243151] explicit source/target for links
- * Michael Golubev (Montages) - API extracted to gmf.tooling.runtime, template migrated to Xtend2
- * Christian W. Damus (CEA) - bug 426732: override the cross-reference searches for views to use the CrossReferenceAdapter
- */
-package aspects.xpt.diagram.updater
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagramUpdater
-import xpt.Common
-
-@Singleton class NodeDescriptor extends xpt.diagram.updater.NodeDescriptor {
- @Inject extension Common;
-
- override def extendsList(GenDiagramUpdater it) '''extends org.eclipse.papyrus.infra.gmfdiag.common.updater.UpdaterNodeDescriptor'''
-
- override def constructor(GenDiagramUpdater it) '''
- «generatedMemberComment»
- public «className(it)»(org.eclipse.emf.ecore.EObject modelElement, String visualID) {
- super(modelElement, visualID);
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend
deleted file mode 100644
index bc7e4fc26bb..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/diagram/views/ViewStyles.xtend
+++ /dev/null
@@ -1,54 +0,0 @@
-/**
- * Copyright (c) 2007, 2009 Borland Software Corporation
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Artem Tikhomirov (Borland) - [257119] Create views directly, not through ViewFactories
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.diagram.views
-
-import aspects.xpt.Common
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenExternalNodeLabel
-import org.eclipse.gmf.codegen.gmfgen.GenLabel
-import xpt.diagram.Utils_qvto
-import xpt.diagram.ViewmapAttributesUtils_qvto
-
-/**
- * Renamed from xpt::diagram::views::Utils.xpt
- * in order to have consistent naming between Xtend files migrated from _qvto helpers and xpt templates
- */
-@Singleton class ViewStyles extends xpt.diagram.views.ViewStyles{
- @Inject extension Common;
- @Inject extension ViewmapAttributesUtils_qvto;
- @Inject extension Utils_qvto;
-
-
-
- override dispatch offset(GenExternalNodeLabel it, String viewVar) '''
- «IF labelOffsetX(viewmap, 0) != 0 || labelOffsetY(viewmap, 0) != 0»
- «offset(it,viewVar, labelOffsetX(viewmap, 0), labelOffsetY(viewmap, 0))»
- «ELSE»
- «offset(it,viewVar, 0, 15)»
- «ENDIF»
- '''
-
- override def offset(GenLabel it, String viewVar, int x, int y) '''
- «val location = stringUniqueIdentifier.toFirstLower+'_Location'»
- org.eclipse.gmf.runtime.notation.Location «location» = (org.eclipse.gmf.runtime.notation.Location) «viewVar».getLayoutConstraint();
- «IF it.getDiagram().isPixelMapMode()»
- «location».setX(«x»);
- «location».setY(«y»);
- «ELSE»
- «location».setX(org.eclipse.gmf.runtime.diagram.ui.util.MeasurementUnitHelper.getMapMode(«viewVar».getDiagram().getMeasurementUnit()).DPtoLP(«x»));
- «location».setY(org.eclipse.gmf.runtime.diagram.ui.util.MeasurementUnitHelper.getMapMode(«viewVar».getDiagram().getMeasurementUnit()).DPtoLP(«y»));
- «ENDIF»
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ActionBarContributor.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ActionBarContributor.xtend
deleted file mode 100644
index a9b3fa8ab2d..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ActionBarContributor.xtend
+++ /dev/null
@@ -1,47 +0,0 @@
-/**
- * Copyright (c) 2007, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenEditorView
-import xpt.Common
-
-@Singleton class ActionBarContributor extends xpt.editor.ActionBarContributor {
- @Inject extension Common;
- @Inject Editor xptEditor;
-
- override def ActionBarContributor(GenEditorView it) '''
- «copyright(editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment»
- public class «className(it)» «extendsList(it)» {
-
- «generatedMemberComment»
-
- protected Class<«xptEditor.qualifiedClassName(it)»> getEditorClass() {
- return «xptEditor.qualifiedClassName(it)».class;
- }
-
- «generatedMemberComment»
- protected String getEditorId() {
- return «xptEditor.qualifiedClassName(it)».ID;
- }
- «initMethod(it)»
- «additions(it)»
- }
- '''
-
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/CreationWizard.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/CreationWizard.xtend
deleted file mode 100644
index 29754ba7811..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/CreationWizard.xtend
+++ /dev/null
@@ -1,174 +0,0 @@
-package aspects.xpt.editor
-
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Common
-import com.google.inject.Inject
-import xpt.CodeStyle
-import xpt.editor.GenDiagram_qvto
-import xpt.editor.CreationWizardPage
-import xpt.Externalizer
-import plugin.Activator
-import xpt.editor.DiagramEditorUtil
-import xpt.ExternalizerUtils_qvto
-import com.google.inject.Singleton
-
-@Singleton class CreationWizard extends xpt.editor.CreationWizard {
-
- @Inject extension Common
- @Inject extension CodeStyle
- @Inject extension ExternalizerUtils_qvto
- @Inject extension GenDiagram_qvto
-
- @Inject Activator xptActivator
- @Inject CreationWizardPage xptCreationWizardPage
- @Inject DiagramEditorUtil xptDiagramEditorUtil
- @Inject Externalizer xptExternalizer
-
- override CreationWizard(GenDiagram it) '''
- «copyright(editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment»
- public class «className(it)»
- «extendsList(it)» «implementsList(it)» {
-
- «generatedMemberComment»
- private org.eclipse.ui.IWorkbench workbench;
-
- «generatedMemberComment»
- protected org.eclipse.jface.viewers.IStructuredSelection selection;
-
- «generatedMemberComment»
- protected «xptCreationWizardPage.qualifiedClassName(it)» diagramModelFilePage;
-
- «IF standaloneDomainModel(it)»
- «generatedMemberComment»
- protected «xptCreationWizardPage.qualifiedClassName(it)» domainModelFilePage;
- «ENDIF»
-
- «generatedMemberComment»
- protected org.eclipse.emf.ecore.resource.Resource diagram;
-
- «generatedMemberComment»
- private boolean openNewlyCreatedDiagramEditor = true;
-
- «generatedMemberComment»
- public org.eclipse.ui.IWorkbench getWorkbench() {
- return workbench;
- }
-
- «generatedMemberComment»
- public org.eclipse.jface.viewers.IStructuredSelection getSelection() {
- return selection;
- }
-
- «generatedMemberComment»
- public final org.eclipse.emf.ecore.resource.Resource getDiagram() {
- return diagram;
- }
-
- «generatedMemberComment»
- public final boolean isOpenNewlyCreatedDiagramEditor() {
- return openNewlyCreatedDiagramEditor;
- }
-
- «generatedMemberComment»
- public void setOpenNewlyCreatedDiagramEditor(boolean openNewlyCreatedDiagramEditor) {
- this.openNewlyCreatedDiagramEditor = openNewlyCreatedDiagramEditor;
- }
-
- «generatedMemberComment»
- public void init(org.eclipse.ui.IWorkbench workbench, org.eclipse.jface.viewers.IStructuredSelection selection) {
- this.workbench = workbench;
- this.selection = selection;
- setWindowTitle(«xptExternalizer.accessorCall(editorGen, titleKey(i18nKeyForCreationWizard(it)))»);
- setDefaultPageImageDescriptor(«xptActivator.qualifiedClassName(editorGen.plugin)».getBundledImageDescriptor(
- "icons/wizban/New«IF domainDiagramElement != null»«domainDiagramElement.genPackage.prefix»«ENDIF»Wizard.gif")); //$NON-NLS-1$
- setNeedsProgressMonitor(true);
- }
-
- «generatedMemberComment»
- public void addPages() {
- diagramModelFilePage = new «xptCreationWizardPage.qualifiedClassName(it)»(
- "DiagramModelFile", getSelection(), "«editorGen.diagramFileExtension»"); //$NON-NLS-1$ //$NON-NLS-2$
- diagramModelFilePage.setTitle(«xptExternalizer.accessorCall(editorGen,
- titleKey(i18nKeyForCreationWizardDiagramPage(it)))»);
- diagramModelFilePage.setDescription(«xptExternalizer.accessorCall(editorGen,
- descriptionKey(i18nKeyForCreationWizardDiagramPage(it)))»);
- addPage(diagramModelFilePage);
- «IF standaloneDomainModel(it)»
-
- domainModelFilePage = new «xptCreationWizardPage.qualifiedClassName(it)»(
- "DomainModelFile", getSelection(), "«editorGen.domainFileExtension»") { //$NON-NLS-1$ //$NON-NLS-2$
-
- «overrideC»
- public void setVisible(boolean visible) {
- if (visible) {
- String fileName = diagramModelFilePage.getFileName();
- fileName = fileName.substring(0, fileName.length() - ".«editorGen.diagramFileExtension»".length()); //$NON-NLS-1$
- setFileName(«xptDiagramEditorUtil.qualifiedClassName(it)».getUniqueFileName(
- getContainerFullPath(), fileName, "«editorGen.domainFileExtension»")); //$NON-NLS-1$
- }
- super.setVisible(visible);
- }
- };
- domainModelFilePage.setTitle(«xptExternalizer.accessorCall(editorGen,
- titleKey(i18nKeyForCreationWizardDomainPage(it)))»);
- domainModelFilePage.setDescription(«xptExternalizer.accessorCall(editorGen,
- descriptionKey(i18nKeyForCreationWizardDomainPage(it)))»);
- addPage(domainModelFilePage);
- «ENDIF»
- }
-
- «generatedMemberComment»
- public boolean performFinish() {
- org.eclipse.jface.operation.IRunnableWithProgress op =
- «IF editorGen.application == null»
- new org.eclipse.ui.actions.WorkspaceModifyOperation(null) {
-
- «overrideC»
- protected void execute(org.eclipse.core.runtime.IProgressMonitor monitor)
- throws org.eclipse.core.runtime.CoreException, InterruptedException {
- «ELSE»
- new org.eclipse.jface.operation.IRunnableWithProgress() {
-
- public void run(org.eclipse.core.runtime.IProgressMonitor monitor)
- throws InvocationTargetException, InterruptedException {
- «ENDIF»
- diagram = «xptDiagramEditorUtil.qualifiedClassName(it)».createDiagram(diagramModelFilePage.getURI(),
- «IF standaloneDomainModel(it)»
- domainModelFilePage.getURI(),
- «ENDIF»
- monitor);
- if (isOpenNewlyCreatedDiagramEditor() && diagram != null) {
- try {
- «xptDiagramEditorUtil.qualifiedClassName(it)».openDiagram(diagram);
- } catch (org.eclipse.ui.PartInitException e) {
- org.eclipse.jface.dialogs.ErrorDialog.openError(getContainer().getShell(),
- «xptExternalizer.accessorCall(editorGen, i18nKeyForCreationWizardOpenEditorError(it))», null, e.getStatus());
- }
- }
- }
- };
- try {
- getContainer().run(false, true, op);
- } catch (InterruptedException e) {
- return false;
- } catch (java.lang.reflect.InvocationTargetException e) {
- if (e.getTargetException() instanceof org.eclipse.core.runtime.CoreException) {
- org.eclipse.jface.dialogs.ErrorDialog.openError(getContainer().getShell(),
- «xptExternalizer.accessorCall(editorGen, i18nKeyForCreationWizardCreationError(it))», null,
- ((org.eclipse.core.runtime.CoreException) e.getTargetException()).getStatus());
- } else {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError(
- "Error creating diagram", e.getTargetException()); //$NON-NLS-1$
- }
- return false;
- }
- return diagram != null;
- }
- «additions(it)»
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DeleteElementAction.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DeleteElementAction.xtend
deleted file mode 100644
index dff428d05d8..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DeleteElementAction.xtend
+++ /dev/null
@@ -1,30 +0,0 @@
-/**
- * Copyright (c) 2008, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2, use GMFT runtime
- * Vincent Lorenzo (CEA LIST)
- *
- */
-package aspects.xpt.editor
-
-import com.google.inject.Singleton
-
-//This class is not used, now we use org.eclipse.papyrus.common.actions.DeleteFromModelAction
-@Singleton class DeleteElementAction extends xpt.editor.DeleteElementAction {
-
-
-
-// override DeleteElementAction(GenDiagram it) '''
-// //This file is not used.
-// //The DeleteElementAction is removed from the plugin and replaced by DeleteFromModelAction in the plugin org.eclipse.diagram.common.
-// '''
-
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramContentInitializer.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramContentInitializer.xtend
deleted file mode 100644
index 02b9853d772..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramContentInitializer.xtend
+++ /dev/null
@@ -1,30 +0,0 @@
-package aspects.xpt.editor
-
-import aspects.xpt.Common
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenContainerBase
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-
-@Singleton class DiagramContentInitializer extends xpt.editor.DiagramContentInitializer {
- @Inject extension Common;
-
- @Inject VisualIDRegistry xptVisualIDRegistry;
-
- override def getCompartment(GenDiagram it) '''
- «generatedMemberComment»
- private org.eclipse.gmf.runtime.notation.Node getCompartment(org.eclipse.gmf.runtime.notation.View node, String visualID) {
- String type = «xptVisualIDRegistry.typeMethodCall(it, 'visualID')»;
- for (java.util.Iterator it = node.getChildren().iterator(); it.hasNext();) {
- org.eclipse.gmf.runtime.notation.View nextView = (org.eclipse.gmf.runtime.notation.View) it.next();
- if (nextView instanceof org.eclipse.gmf.runtime.notation.Node && type.equals(nextView.getType())) {
- return (org.eclipse.gmf.runtime.notation.Node) nextView;
- }
- }
- return null;
- }
- '''
-
- override def createChildrenMethodName(GenContainerBase it) '''create«it.stringUniqueIdentifier»_Children'''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorContextMenuProvider.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorContextMenuProvider.xtend
deleted file mode 100644
index 07c5e97ef5f..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorContextMenuProvider.xtend
+++ /dev/null
@@ -1,83 +0,0 @@
-/**
- * Copyright (c) 2008, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Vincent Lorenzo (CEA LIST)
- */
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import plugin.Activator
-import xpt.Common import xpt.CodeStyle
-
-//We remove the dependance with DeleteElementAction. Now this action is added to the popup menu with the extension point org.eclipse.ui.popup
-//in org.eclipse.papyrus.uml.diagram.common
-@Singleton class DiagramEditorContextMenuProvider extends xpt.editor.DiagramEditorContextMenuProvider {
- @Inject extension Common;
- @Inject extension CodeStyle
-
- @Inject Activator xptActivator;
-
-
- override DiagramEditorContextMenuProvider(GenDiagram it) '''
- «copyright(editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment»
- public class «className(it)» extends org.eclipse.gmf.runtime.diagram.ui.providers.DiagramContextMenuProvider {
-
- «generatedMemberComment»
- private org.eclipse.ui.IWorkbenchPart part;
-
- ««« «generatedMemberComment»
- ««« private «xptDeleteElementAction.qualifiedClassName(it)» deleteAction;
-
- «generatedMemberComment»
- public DiagramEditorContextMenuProvider(org.eclipse.ui.IWorkbenchPart part, org.eclipse.gef.EditPartViewer viewer) {
- super(part, viewer);
- this.part = part;
- ««« deleteAction = new «xptDeleteElementAction.qualifiedClassName(it)»(part);
- ««« deleteAction.init();
- }
-
- ««« «generatedMemberComment»
- ««« public void dispose() {
- ««« if (deleteAction != null) {
- ««« deleteAction.dispose();
- ««« deleteAction = null;
- ««« }
- ««« super.dispose();
- ««« }
-
- «generatedMemberComment»
- public void buildContextMenu(final org.eclipse.jface.action.IMenuManager menu) {
- getViewer().flush();
- try {
- org.eclipse.emf.transaction.util.TransactionUtil.getEditingDomain(
- (org.eclipse.emf.ecore.EObject) getViewer().getContents().getModel()).runExclusive(new Runnable() {
-
- «overrideI(it.editorGen.diagram)»
- public void run() {
- org.eclipse.gmf.runtime.common.ui.services.action.contributionitem.ContributionItemService.getInstance().contributeToPopupMenu(
- DiagramEditorContextMenuProvider.this, part);
- menu.remove(org.eclipse.gmf.runtime.diagram.ui.actions.ActionIds.ACTION_DELETE_FROM_MODEL);
- ««« menu.appendToGroup("editGroup", deleteAction);
- }
- });
- } catch (Exception e) {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError("Error building context menu", e);
- }
- }
- «additions(it)»
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorUtil.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorUtil.xtend
deleted file mode 100644
index 0fa3f092235..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DiagramEditorUtil.xtend
+++ /dev/null
@@ -1,106 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 CEA LIST and other.
- *
- * 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:
- * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - #510281 change dependency to replace gmft-runtime
- *****************************************************************************/
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import xpt.Common
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Externalizer
-import xpt.CodeStyle
-import metamodel.MetaModel
-import plugin.Activator
-import xpt.editor.GenDiagram_qvto
-import com.google.inject.Singleton
-
-@Singleton class DiagramEditorUtil extends xpt.editor.DiagramEditorUtil {
-
- @Inject extension Common
- @Inject extension CodeStyle
- @Inject extension GenDiagram_qvto
-
- @Inject Activator xptActivator
- @Inject Externalizer xptExternalizer
- @Inject MetaModel xptMetaModel
-
- override def getUniqueFileNameMethod(GenDiagram it) '''
- «generatedMemberComment»
- public static String getUniqueFileName(org.eclipse.core.runtime.IPath containerFullPath, String fileName, String extension) {
- return org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.part.DefaultDiagramEditorUtil.getUniqueFileName(containerFullPath, fileName, extension, «»
- org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.part.DefaultDiagramEditorUtil.«IF editorGen.application == null»EXISTS_IN_WORKSPACE«ELSE»EXISTS_AS_IO_FILE«ENDIF»);
- }
- '''
-
- override createDiagramMethod(GenDiagram it) '''
- «generatedMemberComment(
- (if(editorGen.application == null) 'This method should be called within a workspace modify operation since it creates resources.' else ''))»
- public static org.eclipse.emf.ecore.resource.Resource createDiagram(org.eclipse.emf.common.util.URI diagramURI,«IF standaloneDomainModel(
- it)» org.eclipse.emf.common.util.URI modelURI,«ENDIF» org.eclipse.core.runtime.IProgressMonitor progressMonitor) {
- org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain = org.eclipse.emf.workspace.WorkspaceEditingDomainFactory.INSTANCE.createEditingDomain();
- progressMonitor.beginTask(«xptExternalizer.accessorCall(editorGen, i18nKeyForCreateDiagramProgressTask(it))», 3);
- final org.eclipse.emf.ecore.resource.Resource diagramResource = editingDomain.getResourceSet().createResource(diagramURI);
- «IF standaloneDomainModel(it)»
- final org.eclipse.emf.ecore.resource.Resource modelResource = editingDomain.getResourceSet().createResource(modelURI);
- «ELSEIF domainDiagramElement != null && hasDocumentRoot(it)/*for standalone models, we assume its resourcefactory would be able to set extendedMetaData option*/»
- ((org.eclipse.emf.ecore.xmi.XMLResource) diagramResource).getDefaultSaveOptions().put(org.eclipse.emf.ecore.xmi.XMLResource.OPTION_EXTENDED_META_DATA, Boolean.TRUE);
- ((org.eclipse.emf.ecore.xmi.XMLResource) diagramResource).getDefaultLoadOptions().put(org.eclipse.emf.ecore.xmi.XMLResource.OPTION_EXTENDED_META_DATA, Boolean.TRUE);
- «ENDIF»
- final String diagramName = diagramURI.lastSegment();
- org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand command = new org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand(editingDomain, «xptExternalizer.
- accessorCall(editorGen, i18nKeyForCreateDiagramCommandLabel(it))», java.util.Collections.EMPTY_LIST) {
- «overrideC»
- protected org.eclipse.gmf.runtime.common.core.command.CommandResult doExecuteWithResult(org.eclipse.core.runtime.IProgressMonitor monitor, org.eclipse.core.runtime.IAdaptable info) throws org.eclipse.core.commands.ExecutionException {
- «IF domainDiagramElement != null»
- «xptMetaModel.QualifiedClassName(domainDiagramElement)» model = createInitialModel();
- attachModelToResource(model, «IF standaloneDomainModel(it)»model«ELSE»diagram«ENDIF»Resource);
- «ENDIF»
- «extraLineBreak»
- org.eclipse.gmf.runtime.notation.Diagram diagram = org.eclipse.gmf.runtime.diagram.core.services.ViewService.createDiagram(
- «IF domainDiagramElement != null»
- «xptMetaModel.DowncastToEObject(domainDiagramElement, 'model')»,
- «ENDIF»
- «VisualIDRegistry::modelID(it)», «xptActivator.preferenceHintAccess(editorGen)»);
- if (diagram != null) {
- diagramResource.getContents().add(diagram);
- diagram.setName(diagramName);
- «IF domainDiagramElement != null»
- diagram.setElement(«xptMetaModel.DowncastToEObject(domainDiagramElement, 'model')»);
- «ENDIF»
- }
-
- try {
- «IF standaloneDomainModel(it)»modelResource.save(«callGetSaveOptions(it)»);«ENDIF»
- diagramResource.save(«callGetSaveOptions(it)»);
- } catch (java.io.IOException e) {
- «/*
- * TODO CommandResult.newErrorCommandResult(e) would be better? Or even throw ExecutionEx?
- * */
- extraLineBreak»
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError("Unable to store model and diagram resources", e); «nonNLS(1)»
- }
- return org.eclipse.gmf.runtime.common.core.command.CommandResult.newOKCommandResult();
- }
- };
- try {
- org.eclipse.core.commands.operations.OperationHistoryFactory.getOperationHistory().execute(command, new org.eclipse.core.runtime.SubProgressMonitor(progressMonitor, 1), null);
- } catch (org.eclipse.core.commands.ExecutionException e) {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError("Unable to create model and diagram", e); «nonNLS(
- 1)»
- }
- «IF editorGen.application == null»
- «IF standaloneDomainModel(it)»setCharset(org.eclipse.emf.workspace.util.WorkspaceSynchronizer.getFile(modelResource));«ENDIF»
- setCharset(org.eclipse.emf.workspace.util.WorkspaceSynchronizer.getFile(diagramResource));
- «ENDIF»
- return diagramResource;
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DocumentProvider.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DocumentProvider.xtend
deleted file mode 100644
index 5d809566671..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/DocumentProvider.xtend
+++ /dev/null
@@ -1,336 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import plugin.Activator
-import xpt.Common
-import xpt.Externalizer
-import xpt.CodeStyle
-import xpt.editor.DiagramEditorUtil
-
-@Singleton class DocumentProvider extends xpt.editor.DocumentProvider {
- @Inject extension Common;
- @Inject extension CodeStyle
-
- @Inject Activator xptActivator;
- @Inject Externalizer xptExternalizer;
- @Inject DiagramEditorUtil xptDiagramEditorUtil
-
-
-
- override setDocumentContent(GenDiagram it) '''
- «generatedMemberComment»
- protected void setDocumentContent(org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDocument document, org.eclipse.ui.IEditorInput element) throws org.eclipse.core.runtime.CoreException {
- org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDiagramDocument diagramDocument = (org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDiagramDocument) document;
- org.eclipse.emf.transaction.TransactionalEditingDomain domain = diagramDocument.getEditingDomain();
- «IF null == it.editorGen.application»if (element instanceof «fileEditorInputClassFQName(it)») {
- org.eclipse.core.resources.IStorage storage = ((«fileEditorInputClassFQName(it)») element).getStorage();
- org.eclipse.gmf.runtime.notation.Diagram diagram = org.eclipse.gmf.runtime.diagram.ui.resources.editor.internal.util.DiagramIOUtil.load(domain, storage, true, getProgressMonitor());
- document.setContent(diagram);
- } else «ENDIF»if(element instanceof «uriEditorInputClassFQName(it)») {
- org.eclipse.emf.common.util.URI uri = ((«uriEditorInputClassFQName(it)») element).getURI();
- org.eclipse.emf.ecore.resource.Resource resource = null;
- try {
- resource = domain.getResourceSet().getResource(uri.trimFragment(), false);
- if (resource == null) {
- resource = domain.getResourceSet().createResource(uri.trimFragment());
- }
- if (!resource.isLoaded()) {
- try {
- @SuppressWarnings({ "rawtypes", "unchecked" })
- java.util.Map<?,?> options = new java.util.HashMap(org.eclipse.gmf.runtime.emf.core.resources.GMFResourceFactory.getDefaultLoadOptions());
- // @see 171060
- // options.put(org.eclipse.emf.ecore.xmi.XMLResource.OPTION_RECORD_UNKNOWN_FEATURE, Boolean.TRUE);
- resource.load(options);
- } catch (java.io.IOException e) {
- resource.unload();
- throw e;
- }
- }
- if (uri.fragment() != null) {
- org.eclipse.emf.ecore.EObject rootElement = resource.getEObject(uri.fragment());
- if (rootElement instanceof org.eclipse.gmf.runtime.notation.Diagram) {
- document.setContent(rootElement);
- return;
- }
- } else {
- for (java.util.Iterator<org.eclipse.emf.ecore.EObject> it = resource.getContents().iterator(); it.hasNext();) {
- Object rootElement = it.next();
- if (rootElement instanceof org.eclipse.gmf.runtime.notation.Diagram) {
- document.setContent(rootElement);
- return;
- }
- }
- }
- throw new RuntimeException(«xptExternalizer.accessorCall(editorGen, i18nKeyForDocumentProviderNoDiagramInResourceError(it))»);
- } catch (Exception e) {
- org.eclipse.core.runtime.CoreException thrownExcp = null;
- if (e instanceof org.eclipse.core.runtime.CoreException) {
- thrownExcp = (org.eclipse.core.runtime.CoreException) e;
- } else {
- String msg = e.getLocalizedMessage();
- thrownExcp = new org.eclipse.core.runtime.CoreException(new org.eclipse.core.runtime.Status(org.eclipse.core.runtime.IStatus.ERROR, «xptActivator.qualifiedClassName(it.editorGen.plugin)».ID, 0,
- msg != null ? msg : «xptExternalizer.accessorCall(editorGen, i18nKeyForDocumentProviderDiagramLoadingError(it))», e));
- }
- throw thrownExcp;
- }
- } else {
- «throwIncorrectInputException(it)»
- }
- }
- '''
-
- override createEditingDomain(GenDiagram it) '''
- «generatedMemberComment»
- private org.eclipse.emf.transaction.TransactionalEditingDomain createEditingDomain() {
- org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain = org.eclipse.gmf.runtime.diagram.core.DiagramEditingDomainFactory.getInstance().createEditingDomain();
- editingDomain.setID("«editingDomainID»"); «nonNLS(1)»
- final org.eclipse.emf.transaction.NotificationFilter diagramResourceModifiedFilter = org.eclipse.emf.transaction.NotificationFilter.createNotifierFilter(editingDomain.getResourceSet()).and(org.eclipse.emf.transaction.NotificationFilter.createEventTypeFilter(org.eclipse.emf.common.notify.Notification.ADD)).and(org.eclipse.emf.transaction.NotificationFilter.createFeatureFilter(org.eclipse.emf.ecore.resource.ResourceSet.class, org.eclipse.emf.ecore.resource.ResourceSet.RESOURCE_SET__RESOURCES));
- editingDomain.getResourceSet().eAdapters().add(new org.eclipse.emf.common.notify.Adapter() {
-
- private org.eclipse.emf.common.notify.Notifier myTarger;
-
- «overrideI»
- public org.eclipse.emf.common.notify.Notifier getTarget() {
- return myTarger;
- }
-
- «overrideI»
- public boolean isAdapterForType(Object type) {
- return false;
- }
-
- «overrideI»
- public void notifyChanged(org.eclipse.emf.common.notify.Notification notification) {
- if (diagramResourceModifiedFilter.matches(notification)) {
- Object value = notification.getNewValue();
- if (value instanceof org.eclipse.emf.ecore.resource.Resource) {
- ((org.eclipse.emf.ecore.resource.Resource) value).setTrackingModification(true);
- }
- }
- }
-
- «overrideI»
- public void setTarget(org.eclipse.emf.common.notify.Notifier newTarget) {
- myTarger = newTarget;
- }
-
- });
-
- return editingDomain;
- }
- '''
-
- override doSaveDocument(GenDiagram it) '''
- «generatedMemberComment»
- protected void doSaveDocument(org.eclipse.core.runtime.IProgressMonitor monitor, Object element, org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDocument document, boolean overwrite) throws org.eclipse.core.runtime.CoreException {
- ResourceSetInfo info = getResourceSetInfo(element);
- if (info != null) {
- if (!overwrite && !info.isSynchronized()) {
- throw new org.eclipse.core.runtime.CoreException(new org.eclipse.core.runtime.Status(org.eclipse.core.runtime.IStatus.ERROR, «xptActivator.qualifiedClassName(editorGen.plugin)».ID,
- «IF null == editorGen.application»org.eclipse.core.resources.IResourceStatus.OUT_OF_SYNC_LOCAL«ELSE»org.eclipse.core.runtime.IStatus.ERROR«ENDIF»,
- «xptExternalizer.accessorCall(editorGen, i18nKeyForDocumentUnsynchronizedFileSaveError(it))»,
- null));
- }
- «IF null == editorGen.application»
- info.stopResourceListening();
- «ENDIF»
- fireElementStateChanging(element);
- try {
- monitor.beginTask(«xptExternalizer.accessorCall(editorGen, i18nKeyForDocumentSaveDiagramTask(it))», info.getResourceSet().getResources().size() + 1); //"Saving diagram"
- for (java.util.Iterator<org.eclipse.emf.ecore.resource.Resource> it = info.getLoadedResourcesIterator(); it.hasNext();) {
- org.eclipse.emf.ecore.resource.Resource nextResource = it.next();
- monitor.setTaskName(org.eclipse.osgi.util.NLS.bind(
- «xptExternalizer.accessorCall(editorGen, i18nKeyForDocumentSaveNextResourceTask(it))»,
- nextResource.getURI()));
- if (nextResource.isLoaded() && !info.getEditingDomain().isReadOnly(nextResource)) {
- try {
- nextResource.save(«xptDiagramEditorUtil.callGetSaveOptions(it)»);
- } catch (java.io.IOException e) {
- fireElementStateChangeFailed(element);
- throw new org.eclipse.core.runtime.CoreException(new org.eclipse.core.runtime.Status(org.eclipse.core.runtime.IStatus.ERROR, «xptActivator.qualifiedClassName(editorGen.plugin)».ID, org.eclipse.gmf.runtime.diagram.ui.resources.editor.internal.EditorStatusCodes.RESOURCE_FAILURE, e.getLocalizedMessage(), null));
- }
- }
- monitor.worked(1);
- }
- monitor.done();
- info.setModificationStamp(computeModificationStamp(info));
- } catch (RuntimeException x) {
- fireElementStateChangeFailed(element);
- throw x;
- } «IF null == editorGen.application» finally {
- info.startResourceListening();
- } «ENDIF»
- } else {
- org.eclipse.emf.common.util.URI newResoruceURI;
- java.util.List<org.eclipse.core.resources.IFile> affectedFiles = null;
- «IF null == editorGen.application»if (element instanceof «fileEditorInputClassFQName(it)») {
- org.eclipse.core.resources.IFile newFile = ((«fileEditorInputClassFQName(it)») element).getFile();
- affectedFiles = java.util.Collections.singletonList(newFile);
- newResoruceURI = org.eclipse.emf.common.util.URI.createPlatformResourceURI(newFile.getFullPath().toString(), true);
- } else «ENDIF»if(element instanceof «uriEditorInputClassFQName(it)») {
- newResoruceURI = ((«uriEditorInputClassFQName(it)») element).getURI();
- } else {
- fireElementStateChangeFailed(element);
- «throwIncorrectInputException(it)»
- }
- if (false == document instanceof org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDiagramDocument) {
- fireElementStateChangeFailed(element);
- throw new org.eclipse.core.runtime.CoreException(new org.eclipse.core.runtime.Status(org.eclipse.core.runtime.IStatus.ERROR, «xptActivator.qualifiedClassName(editorGen.plugin)».ID, 0,
- "Incorrect document used: " + document + " instead of org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDiagramDocument", null)); «nonNLS(1)» «nonNLS(2)»
- }
- org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDiagramDocument diagramDocument = (org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDiagramDocument) document;
- final org.eclipse.emf.ecore.resource.Resource newResource = diagramDocument.getEditingDomain().getResourceSet().createResource(newResoruceURI);
- final org.eclipse.gmf.runtime.notation.Diagram diagramCopy = org.eclipse.emf.ecore.util.EcoreUtil.copy(diagramDocument.getDiagram());
- try {
- new org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand(diagramDocument.getEditingDomain(), org.eclipse.osgi.util.NLS.bind(«xptExternalizer.accessorCall(editorGen, i18nKeyForDocumentSaveAs(it))», diagramCopy.getName()), affectedFiles) {
- «overrideC»
- protected org.eclipse.gmf.runtime.common.core.command.CommandResult doExecuteWithResult(org.eclipse.core.runtime.IProgressMonitor monitor, org.eclipse.core.runtime.IAdaptable info) throws org.eclipse.core.commands.ExecutionException {
- newResource.getContents().add(diagramCopy);
- return org.eclipse.gmf.runtime.common.core.command.CommandResult.newOKCommandResult();
- }
- }.execute(monitor, null);
- newResource.save(«xptDiagramEditorUtil.callGetSaveOptions(it)»);
- } catch (org.eclipse.core.commands.ExecutionException e) {
- fireElementStateChangeFailed(element);
- throw new org.eclipse.core.runtime.CoreException(new org.eclipse.core.runtime.Status(org.eclipse.core.runtime.IStatus.ERROR, «xptActivator.qualifiedClassName(editorGen.plugin)».ID, 0, e.getLocalizedMessage(), null));
- } catch (java.io.IOException e) {
- fireElementStateChangeFailed(element);
- throw new org.eclipse.core.runtime.CoreException(new org.eclipse.core.runtime.Status(org.eclipse.core.runtime.IStatus.ERROR, «xptActivator.qualifiedClassName(editorGen.plugin)».ID, 0, e.getLocalizedMessage(), null));
- }
- newResource.unload();
- }
- }
- '''
-
- override computeSchedulingRule(GenDiagram it) '''
- «generatedMemberComment»
- private org.eclipse.core.runtime.jobs.ISchedulingRule computeSchedulingRule(org.eclipse.core.resources.IResource toCreateOrModify) {
- if (toCreateOrModify.exists()) {
- return org.eclipse.core.resources.ResourcesPlugin.getWorkspace().getRuleFactory().modifyRule(toCreateOrModify);
- }
- org.eclipse.core.resources.IResource parent = toCreateOrModify;
- do {«/*FIXME [MG] the bug is closed long ago, still need? */»
- /*
- * XXX This is a workaround for
- * https://bugs.eclipse.org/bugs/show_bug.cgi?id=67601
- * IResourceRuleFactory.createRule should iterate the hierarchy
- * itself.
- */
- toCreateOrModify = parent;
- parent = toCreateOrModify.getParent();
- } while (parent != null && !parent.exists());
-
- return org.eclipse.core.resources.ResourcesPlugin.getWorkspace().getRuleFactory().createRule(toCreateOrModify);
- }
- '''
-
- override doValidateState(GenDiagram it) '''
- «generatedMemberComment»
- protected void doValidateState(Object element, Object computationContext) throws org.eclipse.core.runtime.CoreException {
- ResourceSetInfo info = getResourceSetInfo(element);
- if (info != null) {
- java.util.LinkedList<org.eclipse.core.resources.IFile> files2Validate = new java.util.LinkedList<org.eclipse.core.resources.IFile>();
- for (java.util.Iterator<org.eclipse.emf.ecore.resource.Resource> it = info.getLoadedResourcesIterator(); it.hasNext();) {
- org.eclipse.emf.ecore.resource.Resource nextResource = it.next();
- org.eclipse.core.resources.IFile file = org.eclipse.emf.workspace.util.WorkspaceSynchronizer.getFile(nextResource);
- if (file != null && file.isReadOnly()) {
- files2Validate.add(file);
- }
- }
- org.eclipse.core.resources.ResourcesPlugin.getWorkspace().validateEdit(files2Validate.toArray(new org.eclipse.core.resources.IFile[files2Validate.size()]), computationContext);
- }
-
- super.doValidateState(element, computationContext);
- }
- '''
-
- override getResetRule(GenDiagram it) '''
- «generatedMemberComment»
- protected org.eclipse.core.runtime.jobs.ISchedulingRule getResetRule(Object element) {
- ResourceSetInfo info = getResourceSetInfo(element);
- if (info != null) {
- java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule> rules = new java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule>();
- for (java.util.Iterator<org.eclipse.emf.ecore.resource.Resource> it = info.getLoadedResourcesIterator(); it.hasNext();) {
- org.eclipse.emf.ecore.resource.Resource nextResource = it.next();
- org.eclipse.core.resources.IFile file = org.eclipse.emf.workspace.util.WorkspaceSynchronizer.getFile(nextResource);
- if (file != null) {
- rules.add(org.eclipse.core.resources.ResourcesPlugin.getWorkspace().getRuleFactory().modifyRule(file));
- }
- }
- return new org.eclipse.core.runtime.jobs.MultiRule(rules.toArray(new org.eclipse.core.runtime.jobs.ISchedulingRule[rules.size()]));
- }
- return null;
- }
- '''
-
- override getSaveRule(GenDiagram it) '''
- «generatedMemberComment»
- protected org.eclipse.core.runtime.jobs.ISchedulingRule getSaveRule(Object element) {
- ResourceSetInfo info = getResourceSetInfo(element);
- if (info != null) {
- java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule> rules = new java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule>();
- for (java.util.Iterator<org.eclipse.emf.ecore.resource.Resource> it = info.getLoadedResourcesIterator(); it.hasNext();) {
- org.eclipse.emf.ecore.resource.Resource nextResource = it.next();
- org.eclipse.core.resources.IFile file = org.eclipse.emf.workspace.util.WorkspaceSynchronizer.getFile(nextResource);
- if (file != null) {
- rules.add(computeSchedulingRule(file));
- }
- }
- return new org.eclipse.core.runtime.jobs.MultiRule(rules.toArray(new org.eclipse.core.runtime.jobs.ISchedulingRule[rules.size()]));
- }
- return null;
- }
- '''
-
- override getSynchronizeRule(GenDiagram it) '''
- «generatedMemberComment»
- protected org.eclipse.core.runtime.jobs.ISchedulingRule getSynchronizeRule(Object element) {
- ResourceSetInfo info = getResourceSetInfo(element);
- if (info != null) {
- java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule> rules = new java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule>();
- for (java.util.Iterator<org.eclipse.emf.ecore.resource.Resource> it = info.getLoadedResourcesIterator(); it.hasNext();) {
- org.eclipse.emf.ecore.resource.Resource nextResource = it.next();
- org.eclipse.core.resources.IFile file = org.eclipse.emf.workspace.util.WorkspaceSynchronizer.getFile(nextResource);
- if (file != null) {
- rules.add(org.eclipse.core.resources.ResourcesPlugin.getWorkspace().getRuleFactory().refreshRule(file));
- }
- }
- return new org.eclipse.core.runtime.jobs.MultiRule(rules.toArray(new org.eclipse.core.runtime.jobs.ISchedulingRule[rules.size()]));
- }
- return null;
- }
- '''
-
- override getValidateStateRule(GenDiagram it) '''
- «generatedMemberComment»
- protected org.eclipse.core.runtime.jobs.ISchedulingRule getValidateStateRule(Object element) {
- ResourceSetInfo info = getResourceSetInfo(element);
- if (info != null) {«/*FIXME: [MG] bad copy paste here, files should be <IFile>, its a miracle that it does not fail in runtime at toArray stage */»
- java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule> files = new java.util.LinkedList<org.eclipse.core.runtime.jobs.ISchedulingRule>();
- for (java.util.Iterator<org.eclipse.emf.ecore.resource.Resource> it = info.getLoadedResourcesIterator(); it.hasNext();) {
- org.eclipse.emf.ecore.resource.Resource nextResource = it.next();
- org.eclipse.core.resources.IFile file = org.eclipse.emf.workspace.util.WorkspaceSynchronizer.getFile(nextResource);
- if (file != null) {
- files.add(file);
- }
- }
- return org.eclipse.core.resources.ResourcesPlugin.getWorkspace().getRuleFactory().validateEditRule(files.toArray(new org.eclipse.core.resources.IFile[files.size()]));
- }
- return null;
- }
- '''
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/Editor.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/Editor.xtend
deleted file mode 100644
index 435690d4f88..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/Editor.xtend
+++ /dev/null
@@ -1,550 +0,0 @@
-/**
- * Copyright (c) 2006, 2017 Borland Software Corporation, CEA, and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- * Emilien Perico (Atos Origin) - add code to refactor some classes
- * Christian W. Damus (CEA) - bug 430648
- * Christian W. Damus (CEA) - bug 431023
- * Mickaël ADAM (ALL4TEC) mickael.adam@all4tec.net - Bug 512343
- */
-package aspects.xpt.editor
-
-import aspects.xpt.navigator.NavigatorLinkHelper
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenEditorView
-import org.eclipse.gmf.codegen.gmfgen.GenNavigator
-import org.eclipse.gmf.codegen.gmfgen.Palette
-import xpt.Common
-import xpt.navigator.Utils_qvto
-import xpt.CodeStyle
-
-@Singleton class Editor extends xpt.editor.Editor {
- @Inject extension Common;
- @Inject NavigatorLinkHelper xptNavigatorLinkHelper;
- @Inject extension Utils_qvto;
- @Inject extension CodeStyle
-
- override extendsList(GenEditorView it) '''extends org.eclipse.papyrus.uml.diagram.common.part.UmlGmfDiagramEditor'''
-
- override attributes(GenEditorView it) '''
- «generatedMemberComment»
- public static final String ID = "«ID»"; «nonNLS»
-
- «generatedMemberComment»
-public static final String CONTEXT_ID = "«contextID»"; «nonNLS»
-
-
- ««« Documentation. adds listener for papyrus editors
- «generatedMemberComment»
- private org.eclipse.gef.KeyHandler paletteKeyHandler = null;
-
- «generatedMemberComment»
- private org.eclipse.swt.events.MouseListener paletteMouseListener = null;
-
- ««« Helps to handle correctly the dirty state
- «generatedMemberComment»
- private org.eclipse.papyrus.commands.util.OperationHistoryDirtyState dirtyState;
-
- «generatedMemberComment»
- private org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain;
-
- «generatedMemberComment»
- private org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDocumentProvider documentProvider;
- '''
-
- override constructor(GenEditorView it) '''
- «generatedMemberComment»
- public «className»(org.eclipse.papyrus.infra.core.services.ServicesRegistry servicesRegistry, org.eclipse.gmf.runtime.notation.Diagram diagram) throws org.eclipse.papyrus.infra.core.services.ServiceException{
- super(servicesRegistry, diagram);
-
- ««« Documentation. adds listener for papyrus palette service
- // adds a listener to the palette service, which reacts to palette customizations
- org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteService.getInstance().addProviderChangeListener(this);
-
- «««Share the same editing domain
- // Share the same editing provider
- editingDomain = servicesRegistry.getService(org.eclipse.emf.transaction.TransactionalEditingDomain.class);
- documentProvider = new org.eclipse.papyrus.infra.gmfdiag.common.GmfMultiDiagramDocumentProvider(editingDomain);
-
- // overrides editing domain created by super constructor
- setDocumentProvider(documentProvider);
-
- «««end of listeners addition
- }
- '''
-
- override getNavigatorSelection(GenNavigator it) '''
-
- «generatedMemberComment»
- private org.eclipse.jface.viewers.ISelection getNavigatorSelection() {
- «IF getDiagramTopReference(it) !=null»
- org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDiagramDocument document = getDiagramDocument();
- «ENDIF»
- «xptNavigatorLinkHelper.findSelectionBody(it)»
- }
- '''
-
-override createPaletteRoot (Palette it)'''
- «generatedMemberComment»
- protected org.eclipse.gef.palette.PaletteRoot createPaletteRoot(org.eclipse.gef.palette.PaletteRoot existingPaletteRoot) {
- org.eclipse.gef.palette.PaletteRoot paletteRoot;
- if (existingPaletteRoot == null) {
- paletteRoot = org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteService.getInstance().createPalette(this, getDefaultPaletteContent());
- } else {
- org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteService.getInstance().updatePalette(existingPaletteRoot, this, getDefaultPaletteContent());
- paletteRoot = existingPaletteRoot;
- }
- applyCustomizationsToPalette(paletteRoot);
- return paletteRoot;
- }
-'''
-
-def createPaletteCustomizer (GenEditorView it)'''
- «generatedMemberComment»
- protected org.eclipse.gef.ui.palette.PaletteCustomizer createPaletteCustomizer() {
- return new org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteCustomizer(getPreferenceStore());
- }
-'''
-
-override additions (GenEditorView it)'''
-
- «createEditingDomain(it)»
-
- « configureDiagramEditDomain(it)»
-
- « doSave(it)»
-
- « getDirtyState(it)»
-
- « setUndoContext(it)»
-
- « isDirty(it)»
-
- «««Documentation. adds method to handle palette changes
- « handlePaletteChange(it)»
-
- « dispose(it)»
-
- « getPaletteViewer(it)»
-
- ««« Documentation: (RS) advanced customization abilities
- ««« « createPaletteCustomizer»
-
-
- « constructPaletteViewer(it)»
-
- « createPaletteviewerProvider(it)»
-
- «getGraphicalViewer(it)»
-
- «initializeGraphicalViewer(it)»
-
- «selectionChanged(it)»
-'''
-
-def handlePaletteChange (GenEditorView it) '''
- «generatedMemberComment»
- public void providerChanged(org.eclipse.gmf.runtime.common.core.service.ProviderChangeEvent event) {
- // update the palette if the palette service has changed
- if (org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteService.getInstance().equals(event.getSource())) {
- org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteService.getInstance().updatePalette(getPaletteViewer().getPaletteRoot(), this,
- getDefaultPaletteContent());
- }
- }
-'''
-
-def constructPaletteViewer (GenEditorView it) '''
- «generatedMemberComment»
- protected org.eclipse.gef.ui.palette.PaletteViewer constructPaletteViewer() {
- return new org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteViewer();
- }
-'''
-
-override dispose(GenEditorView it)'''
- «generatedMemberComment»
- public void dispose() {
- // remove palette service listener
- // remove preference listener
- org.eclipse.papyrus.infra.gmfdiag.common.service.palette.PapyrusPaletteService.getInstance().removeProviderChangeListener(this);
-
- if(dirtyState != null) {
- dirtyState.dispose();
- dirtyState = null;
- }
-
- super.dispose();
- }
-'''
-
-def getPaletteViewer (GenEditorView it)'''
- «generatedMemberComment»
- protected org.eclipse.gef.ui.palette.PaletteViewer getPaletteViewer() {
- return getEditDomain().getPaletteViewer();
- }
-'''
-
-override implementsList(Iterable<String> it)'''
- implements org.eclipse.gmf.runtime.common.core.service.IProviderChangeListener
- «IF ! it.isEmpty»,
- «FOR string : it SEPARATOR ', '»
- «implementsListEntry(string)»
- «ENDFOR»
- «ENDIF»
-'''
-
-def implementsListEntry (String it)'''«it»'''
-
-def createPaletteviewerProvider (GenEditorView it)'''
-«generatedMemberComment»
-protected org.eclipse.gef.ui.palette.PaletteViewerProvider createPaletteViewerProvider() {
- getEditDomain().setPaletteRoot(createPaletteRoot(null));
- return new org.eclipse.gef.ui.palette.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.
- */
- «overrideC(it.editorGen.diagram)»
- protected void configurePaletteViewer(org.eclipse.gef.ui.palette.PaletteViewer viewer) {
- super.configurePaletteViewer(viewer);
-
- // customize menu...
- viewer.setContextMenu(new org.eclipse.papyrus.infra.gmfdiag.common.service.palette.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 org.eclipse.gmf.runtime.diagram.ui.internal.parts.PaletteToolTransferDragSourceListener(viewer));
- viewer.setCustomizer(createPaletteCustomizer());
- }
-
- «overrideC(it.editorGen.diagram)»
- public org.eclipse.gef.ui.palette.PaletteViewer createPaletteViewer(org.eclipse.swt.widgets.Composite parent) {
- org.eclipse.gef.ui.palette.PaletteViewer pViewer = constructPaletteViewer();
- pViewer.createControl(parent);
- configurePaletteViewer(pViewer);
- hookPaletteViewer(pViewer);
- return pViewer;
- }
-
- /**
- * @return Palette Key Handler for the palette
- */
- private org.eclipse.gef.KeyHandler getPaletteKeyHandler() {
-
- if (paletteKeyHandler == null) {
-
- paletteKeyHandler = new org.eclipse.gef.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
- */
- «overrideC(it.editorGen.diagram)»
- public boolean keyReleased(org.eclipse.swt.events.KeyEvent event) {
-
- if (event.keyCode == org.eclipse.swt.SWT.Selection) {
-
- org.eclipse.gef.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 org.eclipse.swt.events.MouseListener getPaletteMouseListener() {
-
- if (paletteMouseListener == null) {
-
- paletteMouseListener = new org.eclipse.swt.events.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 org.eclipse.swt.events.MouseListener#mouseDoubleClick(org.eclipse.swt.events.MouseEvent)
- */
- «overrideI(it.editorGen.diagram)»
- public void mouseDoubleClick(org.eclipse.swt.events.MouseEvent e) {
- org.eclipse.gef.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;
- }
- }
-
- «overrideI(it.editorGen.diagram)»
- public void mouseDown(org.eclipse.swt.events.MouseEvent e) {
- // do nothing
- }
-
- «overrideI(it.editorGen.diagram)»
- public void mouseUp(org.eclipse.swt.events.MouseEvent e) {
- // Deactivate current active tool here if a
- // double-click was handled.
- if (clearActiveTool) {
- getPaletteViewer().setActiveTool(null);
- clearActiveTool = false;
- }
-
- }
- };
-
- }
- return paletteMouseListener;
- }
-
- };
- }
-'''
-
-//Not used
-override performSaveAs (GenEditorView it)'''
- «generatedMemberComment»
-protected void performSaveAs(org.eclipse.core.runtime.IProgressMonitor progressMonitor) {
- // Nothing
-}
-'''
-
-//Share the same editing domain
-override getEditingDomain (GenEditorView it)'''
- «generatedMemberComment»
- public org.eclipse.emf.transaction.TransactionalEditingDomain getEditingDomain() {
- return editingDomain;
- }
-'''
-
-def createEditingDomain (GenEditorView it)'''
-«generatedMemberComment»
- protected org.eclipse.emf.transaction.TransactionalEditingDomain createEditingDomain() {
- // Already configured
- return editingDomain;
- }
-'''
-
-
-def configureDiagramEditDomain (GenEditorView it)'''
-«generatedMemberComment»
- protected void configureDiagramEditDomain() {
- super.configureDiagramEditDomain();
- getDiagramEditDomain().getDiagramCommandStack().addCommandStackListener(new org.eclipse.gef.commands.CommandStackListener() {
-
- «overrideI(it.editorGen.diagram)»
- public void commandStackChanged(java.util.EventObject event) {
- if (org.eclipse.swt.widgets.Display.getCurrent() == null) {
- org.eclipse.swt.widgets.Display.getDefault().asyncExec(new Runnable() {
-
- @Override
- public void run() {
- firePropertyChange(org.eclipse.ui.IEditorPart.PROP_DIRTY);
- }
- });
- } else {
- firePropertyChange(org.eclipse.ui.IEditorPart.PROP_DIRTY);
- }
- }
- });
- }
-'''
-
-def doSave (GenEditorView it)'''
-«generatedMemberComment»
- public void doSave(org.eclipse.core.runtime.IProgressMonitor progressMonitor) {
- // The saving of the resource is done by the CoreMultiDiagramEditor
- getDirtyState().saved();
- }
-'''
-
-def getDirtyState (GenEditorView it)'''
-«generatedMemberComment»
- protected org.eclipse.papyrus.commands.util.OperationHistoryDirtyState getDirtyState() {
- if(dirtyState == null) {
- dirtyState = org.eclipse.papyrus.commands.util.OperationHistoryDirtyState.newInstance(getUndoContext(), getOperationHistory());
- }
- return dirtyState;
- }
-'''
-
-def setUndoContext (GenEditorView it)'''
-«generatedMemberComment»
- protected void setUndoContext(org.eclipse.core.commands.operations.IUndoContext context) {
- if(dirtyState != null) {
- dirtyState.dispose();
- dirtyState = null;
- }
-
- super.setUndoContext(context);
- }
-'''
-
-//Fix the dirty state
-def isDirty (GenEditorView it)'''
-«generatedMemberComment»
- public boolean isDirty() {
- return getDirtyState().isDirty();
- }
-'''
-
-//Code refactoring moved in UMLDiagramEditor
-override getDocumentProvider (GenEditorView it)'''
- «generatedMemberComment»
- protected final org.eclipse.gmf.runtime.diagram.ui.resources.editor.document.IDocumentProvider getDocumentProvider(org.eclipse.ui.IEditorInput input) {
- return documentProvider;
- }
-'''
-
-override setDocumentProvider (GenEditorView it)'''
- «generatedMemberComment»
- protected final void setDocumentProvider(org.eclipse.ui.IEditorInput input) {
- // Already set in the constructor
- }
-'''
-
-def getGraphicalViewer (GenEditorView it)'''
-«generatedMemberComment»
- @Override
- public org.eclipse.gef.GraphicalViewer getGraphicalViewer() {
- return super.getGraphicalViewer();
- }
-'''
-
-
-override initializeGraphicalViewer (GenEditorView it)'''
-«generatedMemberComment»
- @Override
- protected void initializeGraphicalViewer() {
- super.initializeGraphicalViewer();
-
- // Enable Drop
- getDiagramGraphicalViewer().addDropTargetListener(
- new org.eclipse.papyrus.uml.diagram.common.listeners.DropTargetListener(getDiagramGraphicalViewer(), org.eclipse.jface.util.LocalSelectionTransfer.getTransfer()) {
-
- @Override
- protected Object getJavaObject(org.eclipse.swt.dnd.TransferData data) {
- // It is usual for the transfer data not to be set because it is available locally
- return LocalSelectionTransfer.getTransfer().getSelection();
- }
-
- @Override
- protected org.eclipse.emf.transaction.TransactionalEditingDomain getTransactionalEditingDomain() {
- return getEditingDomain();
- }
- });
-
- }
-'''
-
-def selectionChanged (GenEditorView it)'''
-«generatedMemberComment»
- @Override
- public void selectionChanged(org.eclipse.ui.IWorkbenchPart part, org.eclipse.jface.viewers.ISelection selection) {
- if (getSite().getPage().getActiveEditor() instanceof org.eclipse.papyrus.infra.ui.editor.IMultiDiagramEditor) {
- org.eclipse.papyrus.infra.ui.editor.IMultiDiagramEditor editor = (org.eclipse.papyrus.infra.ui.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();
- }
- }
-'''
-
-override getContextID (GenEditorView it)'''
- «generatedMemberComment»
-protected String getContextID() {
- return CONTEXT_ID;
-}
-'''
-
- override getAdapter(GenEditorView it) '''
- «IF !hasPropertySheet(it) || hasNavigator(it)»
-
- «generatedMemberComment»
- @SuppressWarnings("rawtypes")
- public Object getAdapter(Class type) {
- «IF !hasPropertySheet(it)»
- if (type == org.eclipse.ui.views.properties.IPropertySheetPage.class) {
- return null;
- }
- «ENDIF»
- «IF hasNavigator(it)»
- if (type == org.eclipse.ui.part.IShowInTargetList.class) {
- return new org.eclipse.ui.part.IShowInTargetList() {
-
- «overrideI(it.editorGen.diagram)»
- public String[] getShowInTargetIds() {
- return new String[] { org.eclipse.ui.navigator.resources.ProjectExplorer.VIEW_ID };
- }
- };
- }
- «ENDIF»
- return super.getAdapter(type);
- }
- «ENDIF»
- '''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/InitDiagramFileAction.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/InitDiagramFileAction.xtend
deleted file mode 100644
index af515676fe1..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/InitDiagramFileAction.xtend
+++ /dev/null
@@ -1,81 +0,0 @@
-package aspects.xpt.editor
-
-import xpt.Common
-import com.google.inject.Inject
-import plugin.Activator
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Externalizer
-import xpt.ExternalizerUtils_qvto
-import com.google.inject.Singleton
-
-@Singleton class InitDiagramFileAction extends xpt.editor.InitDiagramFileAction {
-
- @Inject extension Common
- @Inject extension ExternalizerUtils_qvto
-
- @Inject Activator xptActivator
- @Inject xpt.editor.DiagramEditorUtil xptDiagramEditorUtil
- @Inject Externalizer xptExternalizer
-
- override classBody_PDE(GenDiagram it) '''
- «generatedMemberComment»
- private org.eclipse.ui.IWorkbenchPart targetPart;
-
- «generatedMemberComment»
- private org.eclipse.emf.common.util.URI domainModelURI;
-
- «generatedMemberComment»
- public void setActivePart(org.eclipse.jface.action.IAction action, org.eclipse.ui.IWorkbenchPart targetPart) {
- this.targetPart = targetPart;
- }
-
- «generatedMemberComment»
- public void selectionChanged(org.eclipse.jface.action.IAction action, org.eclipse.jface.viewers.ISelection selection) {
- domainModelURI = null;
- action.setEnabled(false);
- if (selection instanceof org.eclipse.jface.viewers.IStructuredSelection == false || selection.isEmpty()) {
- return;
- }
- org.eclipse.core.resources.IFile file =
- (org.eclipse.core.resources.IFile) ((org.eclipse.jface.viewers.IStructuredSelection) selection).getFirstElement();
- domainModelURI = org.eclipse.emf.common.util.URI.createPlatformResourceURI(file.getFullPath().toString(), true);
- action.setEnabled(true);
- }
-
- «generatedMemberComment»
- private org.eclipse.swt.widgets.Shell getShell() {
- return targetPart.getSite().getShell();
- }
-
- «generatedMemberComment»
- public void run(org.eclipse.jface.action.IAction action) {
- org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain =
- org.eclipse.emf.workspace.WorkspaceEditingDomainFactory.INSTANCE.createEditingDomain();
- «IF editorGen.sameFileForDiagramAndModel»
- org.eclipse.emf.ecore.resource.ResourceSet resourceSet = new org.eclipse.emf.ecore.resource.impl.ResourceSetImpl();
- «ELSE»
- org.eclipse.emf.ecore.resource.ResourceSet resourceSet = editingDomain.getResourceSet();
- «ENDIF»
- org.eclipse.emf.ecore.EObject diagramRoot = null;
- try {
- org.eclipse.emf.ecore.resource.Resource resource = resourceSet.getResource(domainModelURI, true);
- diagramRoot = resource.getContents().get(0);
- } catch (org.eclipse.emf.common.util.WrappedException ex) {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError(
- "Unable to load resource: " + domainModelURI, ex); «nonNLS(1)»
- }
- if (diagramRoot == null) {
- org.eclipse.jface.dialogs.MessageDialog.openError(getShell(),
- «xptExternalizer.accessorCall(editorGen, titleKey(i18nKeyForInitDiagramFileResourceErrorDialog()))»,
- «xptExternalizer.accessorCall(editorGen, messageKey(i18nKeyForInitDiagramFileResourceErrorDialog()))»);
- return;
- }
- org.eclipse.jface.wizard.Wizard wizard = new «editorGen.diagram.getNewDiagramFileWizardQualifiedClassName()»(domainModelURI, diagramRoot, editingDomain);
- wizard.setWindowTitle(org.eclipse.osgi.util.NLS.bind(
- «xptExternalizer.accessorCall(editorGen, i18nKeyForInitDiagramFileWizardTitle())»,
- «VisualIDRegistry::modelID(editorGen.diagram)»));
- «xptDiagramEditorUtil.qualifiedClassName(editorGen.diagram)».runWizard(getShell(), wizard, "InitDiagramFile"); «nonNLS(
- 1)»
- }
- '''
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ModelElementSelectionPage.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ModelElementSelectionPage.xtend
deleted file mode 100755
index d536a3b4df8..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ModelElementSelectionPage.xtend
+++ /dev/null
@@ -1,21 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2017 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:
- * Benoit Maggi (CEA LIST) benoit.maggi@cea.fr - Initial API and implementation
- *****************************************************************************/
-package aspects.xpt.editor
-
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-
-@Singleton class ModelElementSelectionPage extends xpt.editor.ModelElementSelectionPage{
-
- override def extendsList(GenDiagram it) '''extends org.eclipse.papyrus.infra.gmfdiag.tooling.runtime.part.DefaultModelElementSelectionPage'''
-
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/NewDiagramFileWizard.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/NewDiagramFileWizard.xtend
deleted file mode 100644
index 3e836230ef3..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/NewDiagramFileWizard.xtend
+++ /dev/null
@@ -1,212 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Externalizer
-import xpt.ExternalizerUtils_qvto
-import xpt.Common
-import xpt.editor.ModelElementSelectionPage
-import plugin.Activator
-import xpt.editor.DiagramContentInitializer
-import xpt.CodeStyle
-
-@Singleton class NewDiagramFileWizard extends xpt.editor.NewDiagramFileWizard {
-
- @Inject extension Common
- @Inject extension CodeStyle
- @Inject extension ExternalizerUtils_qvto;
-
- @Inject Activator xptActivator
- @Inject DiagramEditorUtil xptDiagramEditorUtil
- @Inject Externalizer xptExternalizer;
- @Inject DiagramContentInitializer xptDiagramContentInitializer
- @Inject ModelElementSelectionPage xptModelElementSelectionPage
- @Inject xpt.editor.VisualIDRegistry xptVisualIDRegistry
-
- override i18nValues(GenDiagram it) '''
- «xptExternalizer.messageEntry(nameKey(i18nKeyForNewDiagramFileWizardCreationPage(it)), 'Initialize new diagram file')»
- «xptExternalizer.messageEntry(titleKey(i18nKeyForNewDiagramFileWizardCreationPage(it)), 'Diagram file')»
- «xptExternalizer.messageEntry(descriptionKey(i18nKeyForNewDiagramFileWizardCreationPage(it)),
- 'Create new diagram based on {0} model content')»
- «xptExternalizer.messageEntry(nameKey(i18nKeyForNewDiagramFileWizardRootSelectionPage(it)),
- 'Select diagram root element')»
- «xptExternalizer.messageEntry(titleKey(i18nKeyForNewDiagramFileWizardRootSelectionPage(it)), 'Diagram root element')»
- «xptExternalizer.messageEntry(descriptionKey(i18nKeyForNewDiagramFileWizardRootSelectionPage(it)),
- 'Select semantic model element to be depicted on diagram')»
- «xptExternalizer.messageEntry(i18nKeyForNewDiagramFileWizardRootSelectionPageSelectionTitle(it),
- 'Select diagram root element:')»
- «xptExternalizer.messageEntry(i18nKeyForNewDiagramFileWizardRootSelectionPageNoSelectionMessage(it),
- 'Diagram root element is not selected')»
- «xptExternalizer.messageEntry(i18nKeyForNewDiagramFileWizardRootSelectionPageInvalidSelectionMessage(it),
- 'Invalid diagram root element is selected')»
- «xptExternalizer.messageEntry(i18nKeyForNewDiagramFileWizardInitDiagramCommand(it), 'Initializing diagram contents')»
- «xptExternalizer.messageEntry(i18nKeyForNewDiagramFileWizardIncorrectRootError(it),
- 'Incorrect model object stored as a root resource object')»
- '''
-
- override NewDiagramFileWizard(GenDiagram it) '''
- «copyright(editorGen)»
- package «packageName(it)»;
-
- «generatedClassComment»
- public class «className(it)» extends org.eclipse.jface.wizard.Wizard {
-
- «generatedMemberComment»
- private «creationPage(it)» myFileCreationPage;
-
- «generatedMemberComment»
- private «xptModelElementSelectionPage.qualifiedClassName(it)» diagramRootElementSelectionPage;
-
- «generatedMemberComment»
- private org.eclipse.emf.transaction.TransactionalEditingDomain myEditingDomain;
-
- «generatedMemberComment»
- public «className(it)»(org.eclipse.emf.common.util.URI domainModelURI,
- org.eclipse.emf.ecore.EObject diagramRoot,
- org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain) {
- «_assert('domainModelURI != null : \"Domain model uri must be specified\"')»
- «_assert('diagramRoot != null : \"Doagram root element must be specified\"')»
- «_assert('editingDomain != null : \"Editing domain must be specified\"')»
-
- myFileCreationPage = new «creationPage(it)»(«xptExternalizer.accessorCall(editorGen,
- nameKey(i18nKeyForNewDiagramFileWizardCreationPage(it)))», org.eclipse.jface.viewers.StructuredSelection.EMPTY);
- myFileCreationPage.setTitle(«xptExternalizer.accessorCall(editorGen,
- titleKey(i18nKeyForNewDiagramFileWizardCreationPage(it)))»);
- myFileCreationPage.setDescription(org.eclipse.osgi.util.NLS.bind(
- «xptExternalizer.accessorCall(editorGen, descriptionKey(i18nKeyForNewDiagramFileWizardCreationPage(it)))»,
- «VisualIDRegistry::modelID(it)»));
- org.eclipse.core.runtime.IPath filePath;
- String fileName = org.eclipse.emf.common.util.URI.decode(domainModelURI.trimFileExtension().lastSegment());
- if (domainModelURI.isPlatformResource()) {
- filePath = new org.eclipse.core.runtime.Path(domainModelURI.trimSegments(1).toPlatformString(true));
- } else if (domainModelURI.isFile()) {
- filePath = new org.eclipse.core.runtime.Path(domainModelURI.trimSegments(1).toFileString());
- } else {
- // TODO : use some default path
- throw new IllegalArgumentException("Unsupported URI: " + domainModelURI); «nonNLS(1)»
- }
- myFileCreationPage.setContainerFullPath(filePath);
- myFileCreationPage.setFileName(«xptDiagramEditorUtil.qualifiedClassName(it)».getUniqueFileName(
- filePath, fileName, "«editorGen.diagramFileExtension»")); «nonNLS(1)»
-
- diagramRootElementSelectionPage = new DiagramRootElementSelectionPage(«xptExternalizer.accessorCall(editorGen,
- nameKey(i18nKeyForNewDiagramFileWizardRootSelectionPage(it)))»);
- diagramRootElementSelectionPage.setTitle(«xptExternalizer.accessorCall(editorGen,
- titleKey(i18nKeyForNewDiagramFileWizardRootSelectionPage(it)))»);
- diagramRootElementSelectionPage.setDescription(«xptExternalizer.accessorCall(editorGen,
- descriptionKey(i18nKeyForNewDiagramFileWizardRootSelectionPage(it)))»);
- diagramRootElementSelectionPage.setModelElement(diagramRoot);
-
- myEditingDomain = editingDomain;
- }
-
- «generatedMemberComment»
- public void addPages() {
- addPage(myFileCreationPage);
- addPage(diagramRootElementSelectionPage);
- }
-
- «generatedMemberComment»
- public boolean performFinish() {
- java.util.LinkedList<org.eclipse.core.resources.IFile> affectedFiles = new java.util.LinkedList<org.eclipse.core.resources.IFile>();
- «IF null == editorGen.application»
- org.eclipse.core.resources.IFile diagramFile = myFileCreationPage.createNewFile();
- «xptDiagramEditorUtil.callSetCharset(it, 'diagramFile')»
- affectedFiles.add(diagramFile);
- org.eclipse.emf.common.util.URI diagramModelURI = org.eclipse.emf.common.util.URI.createPlatformResourceURI(diagramFile.getFullPath().toString(), true);
- «ELSE»
- org.eclipse.core.runtime.IPath diagramModelPath = myFileCreationPage.getContainerFullPath().append(myFileCreationPage.getFileName());
- org.eclipse.emf.common.util.URI diagramModelURI = org.eclipse.emf.common.util.URI.createFileURI(diagramModelPath.toString());
- «ENDIF»
- org.eclipse.emf.ecore.resource.ResourceSet resourceSet = myEditingDomain.getResourceSet();
- final org.eclipse.emf.ecore.resource.Resource diagramResource = resourceSet.createResource(diagramModelURI);
- org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand command =
- new org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand(
- myEditingDomain, «xptExternalizer.accessorCall(editorGen, i18nKeyForNewDiagramFileWizardInitDiagramCommand(it))», affectedFiles) {
-
- «overrideC»
- protected org.eclipse.gmf.runtime.common.core.command.CommandResult doExecuteWithResult(
- org.eclipse.core.runtime.IProgressMonitor monitor, org.eclipse.core.runtime.IAdaptable info)
- throws org.eclipse.core.commands.ExecutionException {
- String diagramVID = «xptVisualIDRegistry.getDiagramVisualIDMethodCall(it)»(diagramRootElementSelectionPage.getModelElement());
- if (diagramVID.equals(«VisualIDRegistry::visualID(it)»)) {
- return org.eclipse.gmf.runtime.common.core.command.CommandResult.newErrorCommandResult(
- «xptExternalizer.accessorCall(editorGen, i18nKeyForNewDiagramFileWizardIncorrectRootError(it))»);
- }
- org.eclipse.gmf.runtime.notation.Diagram diagram =
- org.eclipse.gmf.runtime.diagram.core.services.ViewService.createDiagram(
- diagramRootElementSelectionPage.getModelElement(), «VisualIDRegistry::modelID(it)»,
- «xptActivator.preferenceHintAccess(editorGen)»);
- diagramResource.getContents().add(diagram);
- «IF editorGen.sameFileForDiagramAndModel»
- diagramResource.getContents().add(diagram.getElement());
- «ENDIF»
- «IF !it.synchronized»
- new «xptDiagramContentInitializer.qualifiedClassName(it)»().initDiagramContent(diagram);
- «ENDIF»
- return org.eclipse.gmf.runtime.common.core.command.CommandResult.newOKCommandResult();
- }
- };
- try {
- org.eclipse.core.commands.operations.OperationHistoryFactory.getOperationHistory().execute(
- command, new org.eclipse.core.runtime.NullProgressMonitor(), null);
- diagramResource.save(«xptDiagramEditorUtil.callGetSaveOptions(it)»);
- «xptDiagramEditorUtil.qualifiedClassName(it)».openDiagram(diagramResource);
- } catch (org.eclipse.core.commands.ExecutionException e) {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError(
- "Unable to create model and diagram", e); «nonNLS(1)»
- } catch (java.io.IOException ex) {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError(
- "Save operation failed for: " + diagramModelURI, ex); «nonNLS(1)»
- } catch (org.eclipse.ui.PartInitException ex) {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError(
- "Unable to open editor", ex); «nonNLS(1)»
- }
- return true;
- }
-
- «generatedClassComment»
- private static class DiagramRootElementSelectionPage extends «xptModelElementSelectionPage.qualifiedClassName(it)» {
-
- «generatedMemberComment»
- protected DiagramRootElementSelectionPage(String pageName) {
- super(pageName);
- }
-
- «generatedMemberComment»
- protected String getSelectionTitle() {
- return «xptExternalizer.accessorCall(editorGen, i18nKeyForNewDiagramFileWizardRootSelectionPageSelectionTitle(it))»;
- }
-
- «generatedMemberComment»
- protected boolean validatePage() {
- if (getModelElement() == null) {
- setErrorMessage(«xptExternalizer.accessorCall(editorGen,
- i18nKeyForNewDiagramFileWizardRootSelectionPageNoSelectionMessage(it))»);
- return false;
- }
- boolean result = org.eclipse.gmf.runtime.diagram.core.services.ViewService.getInstance().provides(
- new org.eclipse.gmf.runtime.diagram.core.services.view.CreateDiagramViewOperation(
- new org.eclipse.gmf.runtime.emf.core.util.EObjectAdapter(getModelElement()),
- «VisualIDRegistry::modelID(it)», «xptActivator.preferenceHintAccess(editorGen)»));
- setErrorMessage(result ? null : «xptExternalizer.accessorCall(editorGen,
- i18nKeyForNewDiagramFileWizardRootSelectionPageInvalidSelectionMessage(it))»);
- return result;
- }
- }
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetInfo.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetInfo.xtend
deleted file mode 100644
index bd5de605a1b..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetInfo.xtend
+++ /dev/null
@@ -1,60 +0,0 @@
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import xpt.Common
-import xpt.CodeStyle
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import com.google.inject.Singleton
-
-@Singleton class ResourceSetInfo extends xpt.editor.ResourceSetInfo {
-
- @Inject extension Common
- @Inject extension CodeStyle
-
- override handleResourceChangedSD(GenDiagram it) '''
- «generatedMemberComment»
- public boolean handleResourceChanged(final org.eclipse.emf.ecore.resource.Resource resource) {
- «updateSynchStateSD(it)»
- org.eclipse.swt.widgets.Display.getDefault().asyncExec(new java.lang.Runnable() {
- «overrideI»
- public void run() {
- handleElementChanged(ResourceSetInfo.this, resource, null);
- }
- });
- return true;
- }
- '''
-
- override handleResourceDeletedSD(GenDiagram it) '''
- «generatedMemberComment»
- public boolean handleResourceDeleted(org.eclipse.emf.ecore.resource.Resource resource) {
- «updateSynchStateSD(it)»
- org.eclipse.swt.widgets.Display.getDefault().asyncExec(new java.lang.Runnable() {
- «overrideI»
- public void run() {
- fireElementDeleted(ResourceSetInfo.this.getEditorInput());
- }
- });
- return true;
- }
- '''
-
- override handleResourceMovedSD(GenDiagram it) '''
- «generatedMemberComment»
- public boolean handleResourceMoved(org.eclipse.emf.ecore.resource.Resource resource, final org.eclipse.emf.common.util.URI newURI) {
- «updateSynchStateSD(it)»
- if (myDocument.getDiagram().eResource() == resource) {
- org.eclipse.swt.widgets.Display.getDefault().asyncExec(new java.lang.Runnable() {
- «overrideI»
- public void run() {
- handleElementMoved(ResourceSetInfo.this.getEditorInput(), newURI);
- }
- });
- } else {
- handleResourceDeleted(resource);
- }
- return true;
- }
- '''
-
-} \ No newline at end of file
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetModificationListener.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetModificationListener.xtend
deleted file mode 100644
index eaddf4da755..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ResourceSetModificationListener.xtend
+++ /dev/null
@@ -1,66 +0,0 @@
-/**
- * Copyright (c) 2007, 2009, 2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Common
-
-@Singleton class ResourceSetModificationListener extends xpt.editor.ResourceSetModificationListener {
- @Inject extension Common;
-
-
-
- override notifyChanged(GenDiagram it) '''
- «generatedMemberComment»
- public void notifyChanged(org.eclipse.emf.common.notify.Notification notification) {
- if (notification.getNotifier() instanceof org.eclipse.emf.ecore.resource.ResourceSet) {
- super.notifyChanged(notification);
- }
- if (!notification.isTouch() && myModifiedFilter.matches(notification)) {
- if (notification.getNotifier() instanceof org.eclipse.emf.ecore.resource.Resource) {
- org.eclipse.emf.ecore.resource.Resource resource = (org.eclipse.emf.ecore.resource.Resource) notification.getNotifier();
- if (resource.isLoaded()) {
- boolean modified = false;
- for (java.util.Iterator<org.eclipse.emf.ecore.resource.Resource> it = myInfo.getLoadedResourcesIterator(); it.hasNext() && !modified;) {
- org.eclipse.emf.ecore.resource.Resource nextResource = it.next();
- if (nextResource.isLoaded()) {
- modified = nextResource.isModified();
- }
- }
- boolean dirtyStateChanged = false;
- synchronized (myInfo) {
- if (modified != myInfo.fCanBeSaved) {
- myInfo.fCanBeSaved = modified;
- dirtyStateChanged = true;
- }
- «IF null == editorGen.application»
- if (!resource.isModified()) {
- myInfo.setSynchronized(resource);
- }
- «ENDIF»
- }
- if (dirtyStateChanged) {
- fireElementDirtyStateChanged(myInfo.getEditorInput(), modified);
-
- if (!modified) {
- myInfo.setModificationStamp(computeModificationStamp(myInfo));
- }
- }
- }
- }
- }
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ValidateAction.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ValidateAction.xtend
deleted file mode 100644
index c22da0057c8..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/ValidateAction.xtend
+++ /dev/null
@@ -1,213 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Dmitry Stadnik (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #386838 - migrate to Xtend2
- */
-package aspects.xpt.editor
-
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import xpt.Common
-import xpt.editor.DiagramEditorUtil
-import xpt.CodeStyle
-import plugin.Activator
-import xpt.providers.ValidationProvider
-
-@Singleton class ValidateAction extends xpt.editor.ValidateAction {
- @Inject extension Common;
- @Inject extension CodeStyle
-
- @Inject DiagramEditorUtil xptDiagramEditorUtil;
- @Inject Activator xptActivator
- @Inject ValidationProvider xptValidationProvider
-
- override runNonUIValidation(GenDiagram it) '''
-
- «generatedMemberComment»
- public static void runNonUIValidation(org.eclipse.gmf.runtime.notation.View view) {
- org.eclipse.swt.widgets.Shell shell = org.eclipse.swt.widgets.Display.getCurrent().getActiveShell();
- if (shell == null) {
- shell = new org.eclipse.swt.widgets.Shell();
- }
-
- org.eclipse.gmf.runtime.diagram.ui.editparts.DiagramEditPart diagramEditPart =
- org.eclipse.gmf.runtime.diagram.ui.OffscreenEditPartFactory.getInstance().createDiagramEditPart(
- view.getDiagram(),shell);
- runValidation(diagramEditPart, view);
- }
- '''
-
- override createMarkersForStatus(GenDiagram it) '''
-
- «generatedMemberComment»
- private static void createMarkers(
- «IF editorGen.application == null»org.eclipse.core.resources.IFile
- «ELSE»org.eclipse.gmf.runtime.notation.View«ENDIF» target,
- org.eclipse.core.runtime.IStatus validationStatus,
- org.eclipse.gmf.runtime.diagram.ui.editparts.DiagramEditPart diagramEditPart) {
- if (validationStatus.isOK()) {
- return;
- }
- final org.eclipse.core.runtime.IStatus rootStatus = validationStatus;
- java.util.List allStatuses = new java.util.ArrayList();
- «xptDiagramEditorUtil.qualifiedClassName(it)».LazyElement2ViewMap element2ViewMap = new «xptDiagramEditorUtil.
- qualifiedClassName(it)».LazyElement2ViewMap(
- diagramEditPart.getDiagramView(),
- collectTargetElements(rootStatus, new java.util.HashSet<org.eclipse.emf.ecore.EObject>(), allStatuses));
- for (java.util.Iterator it = allStatuses.iterator(); it.hasNext();) {
- org.eclipse.emf.validation.model.IConstraintStatus nextStatus =
- (org.eclipse.emf.validation.model.IConstraintStatus) it.next();
- org.eclipse.gmf.runtime.notation.View view = «xptDiagramEditorUtil.qualifiedClassName(it)».findView(
- diagramEditPart, nextStatus.getTarget(), element2ViewMap);
- addMarker(diagramEditPart.getViewer(), target, view.eResource().getURIFragment(view),
- org.eclipse.gmf.runtime.emf.core.util.EMFCoreUtil.getQualifiedName(nextStatus.getTarget(), true),
- nextStatus.getMessage(), nextStatus.getSeverity());
- }
- }
- '''
-
- override createMarkersForDiagnostic(GenDiagram it) '''
-
- «generatedMemberComment»
- private static void createMarkers(
- «IF editorGen.application == null»org.eclipse.core.resources.IFile
- «ELSE»org.eclipse.gmf.runtime.notation.View«ENDIF» target,
- org.eclipse.emf.common.util.Diagnostic emfValidationStatus,
- org.eclipse.gmf.runtime.diagram.ui.editparts.DiagramEditPart diagramEditPart) {
- if (emfValidationStatus.getSeverity() == org.eclipse.emf.common.util.Diagnostic.OK) {
- return;
- }
- final org.eclipse.emf.common.util.Diagnostic rootStatus = emfValidationStatus;
- java.util.List<org.eclipse.emf.common.util.Diagnostic> allDiagnostics = new java.util.ArrayList<org.eclipse.emf.common.util.Diagnostic>();
- «xptDiagramEditorUtil.qualifiedClassName(it)».LazyElement2ViewMap element2ViewMap =
- new «xptDiagramEditorUtil.qualifiedClassName(it)».LazyElement2ViewMap(
- diagramEditPart.getDiagramView(),
- collectTargetElements(rootStatus, new java.util.HashSet<org.eclipse.emf.ecore.EObject>(), allDiagnostics));
- for (java.util.Iterator<org.eclipse.emf.common.util.Diagnostic> it = emfValidationStatus.getChildren().iterator(); it.hasNext();) {
- org.eclipse.emf.common.util.Diagnostic nextDiagnostic = it.next();
- java.util.List<?> data = nextDiagnostic.getData();
- if (data != null && !data.isEmpty() && data.get(0) instanceof org.eclipse.emf.ecore.EObject) {
- org.eclipse.emf.ecore.EObject element = (org.eclipse.emf.ecore.EObject) data.get(0);
- org.eclipse.gmf.runtime.notation.View view = «xptDiagramEditorUtil.qualifiedClassName(it)».findView(
- diagramEditPart, element, element2ViewMap);
- addMarker(diagramEditPart.getViewer(), target, view.eResource().getURIFragment(view),
- org.eclipse.gmf.runtime.emf.core.util.EMFCoreUtil.getQualifiedName(element, true),
- nextDiagnostic.getMessage(), diagnosticToStatusSeverity(nextDiagnostic.getSeverity()));
- }
- }
- }
- '''
-
- override collectTargetElementsFromStatus(GenDiagram it) '''
-
- «generatedMemberComment»
- private static java.util.Set<org.eclipse.emf.ecore.EObject> collectTargetElements(org.eclipse.core.runtime.IStatus status,
- java.util.Set<org.eclipse.emf.ecore.EObject> targetElementCollector, java.util.List<org.eclipse.emf.validation.model.IConstraintStatus> allConstraintStatuses) {
- if (status instanceof org.eclipse.emf.validation.model.IConstraintStatus) {
- targetElementCollector.add(((org.eclipse.emf.validation.model.IConstraintStatus) status).getTarget());
- allConstraintStatuses.add((org.eclipse.emf.validation.model.IConstraintStatus)status);
- }
- if (status.isMultiStatus()) {
- org.eclipse.core.runtime.IStatus[] children = status.getChildren();
- for (int i = 0; i < children.length; i++) {
- collectTargetElements(children[i], targetElementCollector, allConstraintStatuses);
- }
- }
- return targetElementCollector;
- }
- '''
-
- override collectTargetElementsFromDiagnostic(GenDiagram it) '''
-
- «generatedMemberComment»
- private static java.util.Set<org.eclipse.emf.ecore.EObject> collectTargetElements(org.eclipse.emf.common.util.Diagnostic diagnostic,
- java.util.Set<org.eclipse.emf.ecore.EObject> targetElementCollector, java.util.List<org.eclipse.emf.common.util.Diagnostic> allDiagnostics) {
- java.util.List<?> data = diagnostic.getData();
- org.eclipse.emf.ecore.EObject target = null;
- if (data != null && !data.isEmpty() && data.get(0) instanceof org.eclipse.emf.ecore.EObject) {
- target = (org.eclipse.emf.ecore.EObject) data.get(0);
- targetElementCollector.add(target);
- allDiagnostics.add(diagnostic);
- }
- if (diagnostic.getChildren() != null && !diagnostic.getChildren().isEmpty()) {
- for (java.util.Iterator<org.eclipse.emf.common.util.Diagnostic> it = diagnostic.getChildren().iterator(); it.hasNext();) {
- collectTargetElements(it.next(), targetElementCollector, allDiagnostics);
- }
- }
- return targetElementCollector;
- }
- '''
-
- override run(GenDiagram it) '''
-
- «generatedMemberComment»
- public void run() {
- org.eclipse.ui.IWorkbenchPart workbenchPart = page.getActivePart();
- if (workbenchPart instanceof org.eclipse.gmf.runtime.diagram.ui.parts.IDiagramWorkbenchPart) {
- final org.eclipse.gmf.runtime.diagram.ui.parts.IDiagramWorkbenchPart part = (org.eclipse.gmf.runtime.diagram.ui.parts.IDiagramWorkbenchPart) workbenchPart;
- try {
- «IF editorGen.application == null»
- new org.eclipse.ui.actions.WorkspaceModifyDelegatingOperation(
- «ENDIF»
- new org.eclipse.jface.operation.IRunnableWithProgress() {
-
- «overrideI»
- public void run(org.eclipse.core.runtime.IProgressMonitor monitor)
- throws InterruptedException, java.lang.reflect.InvocationTargetException {
- runValidation(part.getDiagramEditPart(), part.getDiagram());
- }
- }
- «IF editorGen.application == null»
- )
- «ENDIF»
- .run(new org.eclipse.core.runtime.NullProgressMonitor());
- } catch (Exception e) {
- «xptActivator.qualifiedClassName(editorGen.plugin)».getInstance().logError("Validation action failed", e); «nonNLS(1)»
- }
- }
- }
- '''
-
- override runValidationWithEP(GenDiagram it) '''
-
- «generatedMemberComment»
- public static void runValidation(org.eclipse.gmf.runtime.diagram.ui.editparts.DiagramEditPart diagramEditPart, org.eclipse.gmf.runtime.notation.View view) {
- final org.eclipse.gmf.runtime.diagram.ui.editparts.DiagramEditPart fpart = diagramEditPart;
- final org.eclipse.gmf.runtime.notation.View fview = view;
- org.eclipse.emf.transaction.TransactionalEditingDomain txDomain = org.eclipse.emf.transaction.util.TransactionUtil.getEditingDomain(view);
- «xptValidationProvider.qualifiedClassName(it)».runWithConstraints(txDomain, new Runnable() {
-
- «overrideI»
- public void run() {
- validate(fpart, fview);
- }
- });
- }
- '''
-
- override runEMFValidator(GenDiagram it) '''
-
- «generatedMemberComment»
- private static org.eclipse.emf.common.util.Diagnostic runEMFValidator(
- org.eclipse.gmf.runtime.notation.View target) {
- if (target.isSetElement() && target.getElement() != null) {
- return new org.eclipse.emf.ecore.util.Diagnostician() {
-
- «overrideC»
- public String getObjectLabel(org.eclipse.emf.ecore.EObject eObject) {
- return org.eclipse.gmf.runtime.emf.core.util.EMFCoreUtil.getQualifiedName(eObject, true);
- }
- }.validate(target.getElement());
- }
- return org.eclipse.emf.common.util.Diagnostic.OK_INSTANCE;
- }
- '''
-}
diff --git a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/VisualIDRegistry.xtend b/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/VisualIDRegistry.xtend
deleted file mode 100644
index e5fe0afb9f3..00000000000
--- a/plugins/developer/org.eclipse.papyrus.def/xtend/aspects/xpt/editor/VisualIDRegistry.xtend
+++ /dev/null
@@ -1,339 +0,0 @@
-/**
- * Copyright (c) 2007, 2010, 2013 Borland Software Corporation and others
- *
- * 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:
- * Alexander Shatalin (Borland) - initial API and implementation
- * Michael Golubev (Montages) - #372479, #386838
- */
-package aspects.xpt.editor
-
-import aspects.xpt.Common
-import com.google.inject.Inject
-import com.google.inject.Singleton
-import metamodel.MetaModel
-import org.eclipse.emf.codegen.ecore.genmodel.GenClass
-import org.eclipse.gmf.codegen.gmfgen.GenCommonBase
-import org.eclipse.gmf.codegen.gmfgen.GenDiagram
-import org.eclipse.gmf.codegen.gmfgen.GenJavaExpressionProvider
-import org.eclipse.gmf.codegen.gmfgen.GenLink
-import org.eclipse.gmf.codegen.gmfgen.TypeModelFacet
-import org.eclipse.gmf.codegen.gmfgen.ValueExpression
-import xpt.CodeStyle
-import xpt.Common_qvto
-import xpt.diagram.editpolicies.LinkUtils_qvto
-import xpt.diagram.updater.Utils_qvto
-
-//XXX: [MG] decide what to do with @MetaDef methods
-@Singleton class VisualIDRegistry extends xpt.editor.VisualIDRegistry {
- @Inject extension MetaModel
- @Inject extension Common
- @Inject extension Common_qvto;
- @Inject extension LinkUtils_qvto;
- @Inject extension Utils_qvto;
-
- @Inject CodeStyle xptCodeStyle;
-
- override getDiagramVisualID(GenDiagram it) '''
- «generatedMemberComment()»
- public static String «getDiagramVisualIDMethodName(it)»(org.eclipse.emf.ecore.EObject domainElement) {
- if (domainElement == null) {
- «unrecognizedVID(it)»
- }
- return «visualID(it)»;
- }
- '''
-
- /**
- * Support for extra contstraints to check about model element.
- * Includes expression fields for interpreted constrains (like ocl or regexp).
- * For each model element that has an associated constraint, there's a method is<DomainElement>_<UID>()
- * that performs extra specification