summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLaurent Wouters2014-04-04 10:21:43 (EDT)
committerLaurent Wouters2014-04-04 10:21:43 (EDT)
commit597f6421c2cfc37ab918a0f962ff722ee7bf84c6 (patch)
tree0ead6df9f2c0f2f9144c0d355d56afe53b65d146
parentea34bc43379d73c297b421c3a16d69f0af8e6e8e (diff)
downloadorg.eclipse.papyrus-597f6421c2cfc37ab918a0f962ff722ee7bf84c6.zip
org.eclipse.papyrus-597f6421c2cfc37ab918a0f962ff722ee7bf84c6.tar.gz
org.eclipse.papyrus-597f6421c2cfc37ab918a0f962ff722ee7bf84c6.tar.bz2
[clean] Retiring org.eclipse.papyrus.uml.compare
Signed-off-by: Laurent Wouters <laurent.wouters@cea.fr>
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.classpath7
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.project28
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.settings/org.eclipse.jdt.core.prefs7
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/META-INF/MANIFEST.MF37
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/about.html28
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/build.properties11
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_16x16.pngbin622 -> 0 bytes
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_32x32.pngbin1022 -> 0 bytes
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_editor.gifbin956 -> 0 bytes
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.pdoc4
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.properties3
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.xml75
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/Activator.java69
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeDiffTab.java26
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeTabFolder.java52
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLTransactionalModelContentMergeViewer.java58
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/editor/UMLCompareEditor.java126
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/factory/UMLCompareEditorFactory.java31
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/internal/handler/UMLCompareEditorHandler.java60
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentDiffEngine.java99
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentMatchEngine.java110
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusDiffEngine.java210
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusMatchEngine.java69
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/PapyrusModelCompareInput.java148
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/RootObject.java57
-rw-r--r--deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/UMLModelCompareEditorInput.java77
26 files changed, 0 insertions, 1392 deletions
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.classpath b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.classpath
deleted file mode 100644
index 6b1d83e..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.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/J2SE-1.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry excluding="org/eclipse/papyrus/uml/compare/tatiana/PapyrusDiffEngine.java|org/eclipse/papyrus/uml/compare/tatiana/PapyrusMatchEngine.java|org/eclipse/papyrus/uml/compare/tatiana/ElementContentDiffEngine.java|org/eclipse/papyrus/uml/compare/tatiana/ElementContentMatchEngine.java" kind="src" path="src"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.project b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.project
deleted file mode 100644
index ef210cd..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.papyrus.uml.compare</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.settings/org.eclipse.jdt.core.prefs b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 44217f8..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,7 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/META-INF/MANIFEST.MF b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/META-INF/MANIFEST.MF
deleted file mode 100644
index 0f1411d..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,37 +0,0 @@
-Manifest-Version: 1.0
-Require-Bundle: org.eclipse.ui,
- org.eclipse.core.runtime,
- org.eclipse.papyrus.infra.core.log;bundle-version="0.10.0",
- org.eclipse.papyrus.infra.emf.compare.common;bundle-version="0.10.0",
- org.eclipse.papyrus.infra.core;bundle-version="0.10.0",
- org.eclipse.papyrus.infra.emf.compare.instance;bundle-version="0.10.0",
- org.eclipse.uml2.uml;bundle-version="4.0.0",
- org.eclipse.compare;bundle-version="3.5.300",
- org.eclipse.emf.compare.diff;bundle-version="1.3.1",
- org.eclipse.papyrus.infra.emf.compare.ui;bundle-version="0.10.0",
- org.eclipse.emf.compare.ui;bundle-version="1.3.1",
- org.eclipse.emf.facet.infra.browser.uicore;bundle-version="0.2.0",
- org.eclipse.emf.compare;bundle-version="1.3.1",
- org.eclipse.emf.compare.match;bundle-version="1.3.1",
- org.eclipse.papyrus.infra.tools;bundle-version="0.10.0",
- org.eclipse.emf.transaction,
- org.eclipse.papyrus.uml.compare.diff;bundle-version="0.10.0",
- org.eclipse.papyrus.infra.emf.compare.diff;bundle-version="0.10.0",
- org.eclipse.core.expressions,
- org.eclipse.papyrus.infra.core.sasheditor;bundle-version="0.10.0",
- org.eclipse.emf.edit.ui;bundle-version="2.8.0",
- org.eclipse.papyrus.infra.widgets;bundle-version="0.10.0",
- org.eclipse.papyrus.infra.emf;bundle-version="0.10.0",
- org.eclipse.ui.ide;bundle-version="3.8.0"
-Export-Package: org.eclipse.papyrus.uml.compare.editor,
- org.eclipse.papyrus.uml.compare.internal.handler
-Bundle-Vendor: %providerName
-Bundle-ActivationPolicy: lazy
-Bundle-Version: 0.10.0.qualifier
-Bundle-Name: %pluginName
-Bundle-Localization: plugin
-Bundle-ManifestVersion: 2
-Bundle-Activator: org.eclipse.papyrus.uml.compare.Activator
-Bundle-SymbolicName: org.eclipse.papyrus.uml.compare;singleton:=true
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
-
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/about.html b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/about.html
deleted file mode 100644
index 82d49bf..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/about.html
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June 5, 2007</p>
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;). 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, &quot;Program&quot; 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 (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content. Check the Redistributor's license that was
-provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/build.properties b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/build.properties
deleted file mode 100644
index 75d6927..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/build.properties
+++ /dev/null
@@ -1,11 +0,0 @@
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- plugin.pdoc,\
- icons/,\
- build.properties,\
- about.html,\
- plugin.properties
-src.includes = about.html
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_16x16.png b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_16x16.png
deleted file mode 100644
index 4e38b20..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_16x16.png
+++ /dev/null
Binary files differ
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_32x32.png b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_32x32.png
deleted file mode 100644
index af0c3a8..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_32x32.png
+++ /dev/null
Binary files differ
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_editor.gif b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_editor.gif
deleted file mode 100644
index e817df6..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/icons/papyrus_compare_editor.gif
+++ /dev/null
Binary files differ
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.pdoc b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.pdoc
deleted file mode 100644
index 5c9b957..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.pdoc
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<doc:Documentation xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:doc="http://www.eclipse.org/papyrus/documentation/plugin/documentation" description="This plugin provides a UML Compare Editor for Papyrus. This CompareEditor is done&#xD;&#xA;to be opened in the sasheditor as the others papyrus editors (diagram and table)&#xD;&#xA;This editor is &quot;partially volatile&quot;, that is to say, we lose all its information when we close it, &#xD;&#xA;but we don't lose it when we close Papyrus or Eclipse (see bug 371606)&#xD;&#xA;">
- <referent firstName="vincent" lastName="lorenzo" eMail="vincent.lorenzo@cea.fr" currentCompany="CEA-LIST"/>
-</doc:Documentation>
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.properties b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.properties
deleted file mode 100644
index a1f9b65..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.properties
+++ /dev/null
@@ -1,3 +0,0 @@
-#Properties file for org.eclipse.papyrus.uml.compare
-providerName = Eclipse Modeling Project
-pluginName = Papyrus UML Compare Editor (Incubation) \ No newline at end of file
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.xml b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.xml
deleted file mode 100644
index a93fcd6..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/plugin.xml
+++ /dev/null
@@ -1,75 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
- <extension
- point="org.eclipse.papyrus.infra.core.papyrusDiagram">
- <editorDiagram
- factoryClass="org.eclipse.papyrus.uml.compare.factory.UMLCompareEditorFactory"
- icon="icons/papyrus_compare_16x16.png">
- </editorDiagram>
- </extension>
- <extension
- point="org.eclipse.ui.commands">
- <command
- categoryId="org.eclipse.papyrus.editor.category"
- description="Create a UML Compare Editor"
- id="org.eclipse.papyrus.uml.compare.command"
- name="UML Compare Editor">
- </command>
- </extension>
- <extension
- point="org.eclipse.ui.handlers">
- <handler
- class="org.eclipse.papyrus.uml.compare.internal.handler.UMLCompareEditorHandler"
- commandId="org.eclipse.papyrus.uml.compare.command">
- <activeWhen>
- <and>
- <with
- variable="activeEditorId">
- <equals
- value="org.eclipse.papyrus.infra.core.papyrusEditor">
- </equals>
- </with>
- </and>
- </activeWhen>
- </handler>
- </extension>
- <extension
- point="org.eclipse.ui.menus">
- <menuContribution
- allPopups="true"
- locationURI="popup:org.eclipse.ui.popup.any">
- <command
- commandId="org.eclipse.papyrus.uml.compare.command"
- icon="icons/papyrus_compare_16x16.png"
- label="Compare 2 UML Elements"
- style="push"
- tooltip="Compare 2 UML Elements">
- <visibleWhen
- checkEnabled="true">
- <or>
- <and>
- <with
- variable="selection">
- <iterate
- ifEmpty="false"
- operator="and">
- <adapt
- type="org.eclipse.emf.ecore.EObject">
- </adapt>
- </iterate>
- </with>
- <with
- variable="activeEditorId">
- <equals
- value="org.eclipse.papyrus.infra.core.papyrusEditor">
- </equals>
- </with>
- </and>
- </or>
- </visibleWhen>
- </command>
- </menuContribution>
- </extension>
-
-</plugin>
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/Activator.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/Activator.java
deleted file mode 100644
index 133ba80..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/Activator.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2012 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:
- * Vincent Lorenzo (CEA LIST) Vincent.Lorenzo@cea.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare;
-
-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.uml.compare"; //$NON-NLS-1$
-
- // The shared instance
- private static Activator plugin;
-
- /** the Papyrus log helper */
- public static LogHelper log;
-
- /**
- * The constructor
- */
- public Activator() {
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
- */
- 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)
- */
- 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/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeDiffTab.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeDiffTab.java
deleted file mode 100644
index d2f83ef..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeDiffTab.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package org.eclipse.papyrus.uml.compare.content.viewer;
-
-import org.eclipse.emf.compare.ui.viewer.content.part.ModelContentMergeTabFolder;
-import org.eclipse.emf.compare.ui.viewer.content.part.diff.ModelContentMergeDiffTab;
-import org.eclipse.papyrus.uml.compare.utils.RootObject;
-import org.eclipse.swt.widgets.Composite;
-
-
-public class UMLModelContentMergeDiffTab extends ModelContentMergeDiffTab {
-
- public UMLModelContentMergeDiffTab(final Composite parentComposite, final int side, final ModelContentMergeTabFolder parentFolder) {
- super(parentComposite, side, parentFolder);
- }
-
- @Override
- public void setReflectiveInput(final Object object) {
- if(object instanceof RootObject) {
- clearCaches();
- setInput(object);
- setupCaches();
- needsRedraw = true;
- } else {
- super.setReflectiveInput(object);
- }
- }
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeTabFolder.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeTabFolder.java
deleted file mode 100644
index 07d1b38..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLModelContentMergeTabFolder.java
+++ /dev/null
@@ -1,52 +0,0 @@
-package org.eclipse.papyrus.uml.compare.content.viewer;
-
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.compare.ui.viewer.content.ModelContentMergeViewer;
-import org.eclipse.emf.compare.ui.viewer.content.part.IModelContentMergeViewerTab;
-import org.eclipse.emf.compare.util.AdapterUtils;
-import org.eclipse.jface.viewers.IContentProvider;
-import org.eclipse.papyrus.infra.emf.compare.ui.content.viewer.PapyrusModelContentMergeTabFolder;
-import org.eclipse.papyrus.uml.compare.utils.RootObject;
-import org.eclipse.swt.widgets.Composite;
-
-
-public class UMLModelContentMergeTabFolder extends PapyrusModelContentMergeTabFolder {
-
- public UMLModelContentMergeTabFolder(ModelContentMergeViewer viewer, Composite composite, int side) {
- super(viewer, composite, side);
- }
-
- /**
- *
- * @returnZ
- */
- protected IContentProvider createDiffTabContentProvider() {
- return new UMLModelContentMergeDiffTabContentProvider(AdapterUtils.getAdapterFactory());
- }
-
-
- @Override
- protected IModelContentMergeViewerTab createModelContentMergeDiffTab(Composite parent) {
- diffTab = new UMLModelContentMergeDiffTab(parent, partSide, this);
- diffTab.setContentProvider(createDiffTabContentProvider());
- return diffTab;
- }
-
- public class UMLModelContentMergeDiffTabContentProvider extends ModelContentMergeDiffTabContentProvider {
-
- public UMLModelContentMergeDiffTabContentProvider(AdapterFactory factory) {
- super(factory);
- }
-
- @Override
- public Object[] getElements(Object object) {
- if(object instanceof RootObject) {
- Object[] result = new Object[1];
- result[0] = ((RootObject)object).getRepresentedObject();
- return result;
- }
- return super.getElements(object);
- }
-
- }
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLTransactionalModelContentMergeViewer.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLTransactionalModelContentMergeViewer.java
deleted file mode 100644
index e9a087b..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/content/viewer/UMLTransactionalModelContentMergeViewer.java
+++ /dev/null
@@ -1,58 +0,0 @@
-package org.eclipse.papyrus.uml.compare.content.viewer;
-
-import org.eclipse.compare.CompareConfiguration;
-import org.eclipse.compare.contentmergeviewer.IMergeViewerContentProvider;
-import org.eclipse.emf.compare.ui.viewer.content.ModelContentMergeContentProvider;
-import org.eclipse.emf.compare.ui.viewer.content.part.ModelContentMergeTabFolder;
-import org.eclipse.papyrus.infra.emf.compare.ui.content.transactional.viewer.PapyrusTransactionalModelContentMergeViewer;
-import org.eclipse.papyrus.uml.compare.utils.RootObject;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IEditorPart;
-
-
-public class UMLTransactionalModelContentMergeViewer extends PapyrusTransactionalModelContentMergeViewer {
-
-
- public UMLTransactionalModelContentMergeViewer(final Composite parent, final CompareConfiguration config, final IEditorPart editor) {
- super(parent, config, editor);
- }
-
-
-
- @Override
- protected IMergeViewerContentProvider createMergeViewerContentProvider() {
- return new ModelContentMergeContentProvider(configuration) {
-
- @Override
- public Object getLeftContent(final Object element) {
- if(element != null) {
- return new RootObject(configuration.getProperty(RootObject.LEFT_OBJECT_KEY));
- }
- return null;
- }
-
- @Override
- public Object getRightContent(final Object element) {
- if(element != null) {
- return new RootObject(configuration.getProperty(RootObject.RIGHT_OBJECT_KEY));
- }
- return null;
- }
- };
-
- }
-
- /**
- *
- * {@inheritDoc}
- *
- * @param composite
- * @param side
- * @return
- */
- @Override
- protected ModelContentMergeTabFolder createModelContentMergeTabFolder(final Composite composite, final int side) {
- return new UMLModelContentMergeTabFolder(this, composite, side);
- }
-
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/editor/UMLCompareEditor.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/editor/UMLCompareEditor.java
deleted file mode 100644
index 4f77deb..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/editor/UMLCompareEditor.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2012 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:
- * Vincent Lorenzo (CEA LIST) Vincent.Lorenzo@cea.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.editor;
-
-import java.util.Map;
-
-import org.eclipse.compare.CompareConfiguration;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.emf.compare.diff.metamodel.ComparisonSnapshot;
-import org.eclipse.emf.compare.diff.metamodel.DiffModel;
-import org.eclipse.emf.compare.match.metamodel.MatchModel;
-import org.eclipse.emf.compare.ui.editor.ModelCompareEditorInput;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.papyrus.infra.core.services.ServicesRegistry;
-import org.eclipse.papyrus.infra.emf.compare.common.editor.EMFCompareEditor;
-import org.eclipse.papyrus.infra.emf.compare.common.utils.PapyrusModelCompareEditorInput;
-import org.eclipse.papyrus.infra.emf.compare.diff.utils.PapyrusCompareOptions;
-import org.eclipse.papyrus.infra.emf.compare.instance.papyrusemfcompareinstance.PapyrusEMFCompareInstance;
-import org.eclipse.papyrus.uml.compare.diff.services.UMLDiffService;
-import org.eclipse.papyrus.uml.compare.diff.services.nested.NestedMatchService;
-import org.eclipse.papyrus.uml.compare.diff.services.nested.NestedMergeUtils;
-import org.eclipse.papyrus.uml.compare.utils.RootObject;
-import org.eclipse.papyrus.uml.compare.utils.UMLModelCompareEditorInput;
-import org.eclipse.uml2.uml.NamedElement;
-
-
-
-public class UMLCompareEditor extends EMFCompareEditor {
-
- /** the type of the editor */
- public static final String EDITOR_TYPE = "PapyrusUMLCompare"; //$NON-NLS-1$
-
- /**
- * @param servicesRegistry
- * @param rawModel
- *
- */
- public UMLCompareEditor(final ServicesRegistry servicesRegistry, final PapyrusEMFCompareInstance rawModel) {
- super(servicesRegistry, rawModel);
- }
-
- /**
- *
- * @see org.eclipse.papyrus.infra.emf.compare.common.editor.AbstractPapyrusCompareEditor#getCompareOptions(org.eclipse.core.runtime.IProgressMonitor,
- * org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EObject)
- *
- * @param monitor
- * @param leftObject
- * @param rightObject
- * @return
- */
- @Override
- protected Map<String, Object> getCompareOptions(final IProgressMonitor monitor, final EObject leftObject, final EObject rightObject) {
- return NestedMergeUtils.getMergeOptions(monitor, leftObject, rightObject);
- }
-
- @Override
- protected MatchModel doMatch(IProgressMonitor monitor, final EObject left, final EObject right, final Map<String, Object> options) throws InterruptedException {
- return NestedMatchService.doContentMatch(left, right, options);
- }
-
- /**
- * A part of this method is duplicated from DiffService#doDiff
- *
- * @param match
- * @return
- */
- @Override
- protected DiffModel doDiff(final MatchModel match, final Map<String, Object> options) {
- return UMLDiffService.doDiff(match, false, options);
- }
-
-
- @Override
- protected ModelCompareEditorInput createModelCompareEditorInput(final ComparisonSnapshot snapshot) {
- return new UMLModelCompareEditorInput(snapshot, this);
- }
-
- @Override
- protected void configureInput(final PapyrusModelCompareEditorInput input) {
-
- //TODO : warning if we use a label provider, warning to the stereotype use
- CompareConfiguration cc = input.getCompareConfiguration();
- ILabelProvider prov = getLabelProvider();
- String leftQName = null;
- String rightQName = null;
- final EObject left = this.rawModel.getLeft();
- if(left instanceof NamedElement) {
- leftQName = ((NamedElement)left).getQualifiedName();
- }
- final EObject right = this.rawModel.getRight();
- if(right instanceof NamedElement) {
- rightQName = ((NamedElement)right).getQualifiedName();
- }
-
- cc.setLeftLabel(leftQName);
- cc.setRightLabel(rightQName);
- cc.setLeftImage(prov.getImage(left));
- cc.setRightImage(prov.getImage(right));
- cc.setProperty(RootObject.LEFT_OBJECT_KEY, rawModel.getLeft());
- cc.setProperty(RootObject.RIGHT_OBJECT_KEY, rawModel.getRight());
-
- //configure the merge options
- final Map<String, Object> options = getCompareOptions(null, left, right);//we are looking for the merge options
- final Boolean leftToRight = (Boolean)options.get(PapyrusCompareOptions.KEY_ALLOW_MERGE_LEFT_TO_RIGHT);
- final Boolean rightToLeft = (Boolean)options.get(PapyrusCompareOptions.KEY_ALLOW_MERGE_RIGHT_TO_LEFT);
- if(rightToLeft != null) {
- cc.setLeftEditable(rightToLeft);
- }
- if(leftToRight != null) {
- cc.setRightEditable(leftToRight);
- }
- };
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/factory/UMLCompareEditorFactory.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/factory/UMLCompareEditorFactory.java
deleted file mode 100644
index 62073e8..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/factory/UMLCompareEditorFactory.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2012 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:
- * Vincent Lorenzo (CEA LIST) Vincent.Lorenzo@cea.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.factory;
-
-import org.eclipse.papyrus.infra.emf.compare.common.factory.AbstractEMFCompareEditorFactory;
-import org.eclipse.papyrus.uml.compare.editor.UMLCompareEditor;
-
-
-public class UMLCompareEditorFactory extends AbstractEMFCompareEditorFactory {
-
- /**
- * Constructor.
- *
- * @param diagramClass
- * @param expectedType
- */
- public UMLCompareEditorFactory() {
- super(UMLCompareEditor.class, UMLCompareEditor.EDITOR_TYPE);
- }
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/internal/handler/UMLCompareEditorHandler.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/internal/handler/UMLCompareEditorHandler.java
deleted file mode 100644
index 5ee57a5..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/internal/handler/UMLCompareEditorHandler.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2012 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:
- * Vincent Lorenzo (CEA LIST) Vincent.Lorenzo@cea.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.internal.handler;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.papyrus.infra.emf.compare.common.handler.AbstractEMFCompareEditorHandler;
-import org.eclipse.papyrus.uml.compare.editor.UMLCompareEditor;
-import org.eclipse.uml2.uml.Element;
-
-/**
- * The handler for the UML Compare Editor
- */
-public class UMLCompareEditorHandler extends AbstractEMFCompareEditorHandler {
-
- public UMLCompareEditorHandler() {
- super(UMLCompareEditor.EDITOR_TYPE);
- }
-
- /**
- *
- * @see org.eclipse.papyrus.infra.emf.compare.common.handler.AbstractEMFCompareEditorHandler#getSelection()
- *
- * @return
- */
- @Override
- protected List<EObject> getSelection() {
- List<EObject> umlSelection = new ArrayList<EObject>();
- for(EObject current : super.getSelection()) {
- if(current instanceof Element) {
- umlSelection.add(current);
- }
- }
- return umlSelection;
- }
-
- @Override
- public boolean isEnabled() {
- boolean enabled = super.isEnabled();
- if(enabled) {
- EObject left = getSelection().get(0);
- EObject right = getSelection().get(1);
- return left.getClass() == right.getClass();
- }
- return false;
- }
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentDiffEngine.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentDiffEngine.java
deleted file mode 100644
index 385ae1e..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentDiffEngine.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2010 CEA LIST.
- *
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Tatiana Fesenko (CEA LIST) - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.tatiana;
-
-import org.eclipse.emf.compare.diff.engine.GenericDiffEngine;
-import org.eclipse.emf.compare.diff.metamodel.DiffElement;
-import org.eclipse.emf.compare.diff.metamodel.DiffGroup;
-import org.eclipse.emf.compare.diff.metamodel.DiffModel;
-import org.eclipse.emf.compare.diff.metamodel.MoveModelElement;
-import org.eclipse.emf.ecore.EObject;
-
-
-/**
- /**
- * The implementation of DiffEngine to compare two arbitrary elements, not nesseserily diagrams
- */
-public class ElementContentDiffEngine extends GenericDiffEngine/*PapyrusDiffEngine*/ {
-
- /** The my left. */
- private final EObject myLeft;
-
- /** The my right. */
- private final EObject myRight;
-
- /**
- * Instantiates a new element content diff engine.
- *
- * @param left the left
- * @param right the right
- */
- public ElementContentDiffEngine(EObject left, EObject right) {
- this.myLeft = left;
- this.myRight = right;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.diff.engine.GenericDiffEngine#addInContainerPackage(org.eclipse.emf.compare.diff.metamodel.DiffGroup, org.eclipse.emf.compare.diff.metamodel.DiffElement, org.eclipse.emf.ecore.EObject)
- */
- @Override
- protected void addInContainerPackage(DiffGroup root, DiffElement operation, EObject targetParent) {
-// if(targetParent == myLeft || targetParent == myRight) {
-// root.getSubDiffElements().add(operation);
-// return;
-// }
- super.addInContainerPackage(root, operation, targetParent);
- }
-
-// /* (non-Javadoc)
-// * @see org.eclipse.papyrus.uml.compare.diff.PapyrusDiffEngine#postProcess(org.eclipse.emf.compare.diff.metamodel.DiffModel)
-// */
-// @Override
-// protected DiffModel postProcess(DiffModel diffModel) {
-// super.postProcess(diffModel);
-// //#336361 - [UML Compare] Compare two elements: show right element as root
-// DiffElement newRoot = findDiffElementFor(diffModel, myRight);
-// CompareTwoElementsDiffModel newRootExt = buildCompareTwoElementsDiff(diffModel, newRoot);
-// return newRootExt;
-// }
-
- /**
- * Builds the compare two elements diff.
- *
- * @param object the object
- * @param newRott the new rott
- * @return the compare two elements diff model
- */
-// private CompareTwoElementsDiffModel buildCompareTwoElementsDiff(DiffModel object, DiffElement newRott) {
-// CompareTwoElementsDiffModel newElement = UMLDiffFactory.eINSTANCE.createCompareTwoElementsDiffModel();
-// newElement.getLeftRoots().add(myLeft);
-// newElement.getRightRoots().add(myRight);
-//// newElement.getAncestorRoots().addAll(object.getAncestorRoots());
-// newElement.getOwnedElements().add(newRott);
-// return newElement;
-// }
-
- /* (non-Javadoc)
- * @see org.eclipse.papyrus.uml.compare.diff.PapyrusDiffEngine#visitElement(org.eclipse.emf.compare.diff.metamodel.DiffModel, org.eclipse.emf.compare.diff.metamodel.DiffElement)
- */
-// @Override
-// protected void visitElement(DiffModel root, DiffElement diffElement) {
-// super.visitElement(root, diffElement);
-// if (diffElement instanceof MoveModelElement) {
-// // don't show 'element moved for the root elements'
-// hideElement(diffElement, null);
-// }
-// }
-
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentMatchEngine.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentMatchEngine.java
deleted file mode 100644
index 63ef73a..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/ElementContentMatchEngine.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2010 CEA LIST.
- *
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Tatiana Fesenko (CEA LIST) - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.tatiana;
-
-import org.eclipse.emf.compare.FactoryException;
-import org.eclipse.emf.compare.match.engine.AbstractSimilarityChecker;
-import org.eclipse.emf.compare.match.engine.GenericMatchEngine;
-import org.eclipse.emf.compare.match.statistic.MetamodelFilter;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.resource.Resource;
-
-/**
- * The implementation of MatchEngine to compare two arbitrary elements, not nesseserily diagrams
- */
-public class ElementContentMatchEngine extends GenericMatchEngine{ //PapyrusMatchEngine {
-
- /** The my left. */
- private final EObject myLeft;
-
- /** The my right. */
- private final EObject myRight;
-
- /**
- * Instantiates a new element content match engine.
- *
- * @param left the left
- * @param right the right
- */
- public ElementContentMatchEngine(EObject left, EObject right) {
- this.myLeft = left;
- this.myRight = right;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.papyrus.uml.compare.match.PapyrusMatchEngine#prepareChecker()
- */
- @Override
- protected AbstractSimilarityChecker prepareChecker() {
- return new AlwaysSimilarChecker(filter, super.prepareChecker());
- }
-
- /**
- * The Class AlwaysSimilarChecker.
- */
- private class AlwaysSimilarChecker extends AbstractSimilarityChecker {
-
- /** The delegate. */
- private AbstractSimilarityChecker delegate;
-
- /**
- * Instantiates a new always similar checker.
- *
- * @param filter the filter
- * @param fallback the fallback
- */
- public AlwaysSimilarChecker(MetamodelFilter filter, AbstractSimilarityChecker fallback) {
- super(filter);
- this.delegate = fallback;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.match.engine.AbstractSimilarityChecker#isSimilar(org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EObject)
- */
- /**
- * The standard AbstractSimilarityChecker checks the parent of the elements,
- * thus, compared elements won't be considered similar.
- * To avoid this problem this method always returns true
- **/
- @Override
- public boolean isSimilar(EObject obj1, EObject obj2) throws FactoryException {
- return true;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.match.engine.AbstractSimilarityChecker#init(org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EObject)
- */
- @Override
- public void init(EObject leftObject, EObject rightObject) throws FactoryException {
- delegate.init(leftObject, rightObject);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.match.engine.AbstractSimilarityChecker#init(org.eclipse.emf.ecore.resource.Resource, org.eclipse.emf.ecore.resource.Resource)
- */
- @Override
- public void init(Resource leftResource, Resource rightResource) throws FactoryException {
- delegate.init(leftResource, rightResource);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.match.engine.AbstractSimilarityChecker#absoluteMetric(org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EObject)
- */
- @Override
- public double absoluteMetric(EObject obj1, EObject obj2) throws FactoryException {
- return delegate.absoluteMetric(obj1, obj2);
- }
- }
-
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusDiffEngine.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusDiffEngine.java
deleted file mode 100644
index e7bc3be..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusDiffEngine.java
+++ /dev/null
@@ -1,210 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2010 CEA LIST.
- *
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Tatiana Fesenko (CEA LIST) - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.tatiana;
-
-
-import java.util.Iterator;
-
-import org.eclipse.emf.compare.diff.engine.GenericDiffEngine;
-import org.eclipse.emf.compare.diff.engine.check.ReferencesCheck;
-import org.eclipse.emf.compare.diff.metamodel.AbstractDiffExtension;
-import org.eclipse.emf.compare.diff.metamodel.DiffElement;
-import org.eclipse.emf.compare.diff.metamodel.DiffFactory;
-import org.eclipse.emf.compare.diff.metamodel.DiffGroup;
-import org.eclipse.emf.compare.diff.metamodel.DiffModel;
-import org.eclipse.emf.compare.diff.metamodel.util.DiffSwitch;
-import org.eclipse.emf.compare.match.metamodel.MatchModel;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.papyrus.uml.compare.UMLCompareUtils;
-import org.eclipse.papyrus.uml.compare.diff.extension.DiffElementExtensionBuilder;
-import org.eclipse.papyrus.uml.compare.diff.metamodel.uml_diff_extension.UMLDiffFactory;
-import org.eclipse.uml2.uml.Element;
-import org.eclipse.uml2.uml.util.UMLUtil;
-
-
-/**
- * Implementation of DiffEngine for UML Diagrams:
- * <li>Properly processes changes stereotypes and tagged values,</li>
- * <li>doesn't show numerous bulk changes as described in Bug 316819#c1</li>
- */
-public class PapyrusDiffEngine extends GenericDiffEngine {
-
- /** The my diff element builder. */
- private DiffSwitch<AbstractDiffExtension> myDiffElementBuilder = new DiffElementExtensionBuilder();
-
- /** The my get model element switch. */
- private DiffSwitch<EObject> myGetModelElementSwitch = new ModelElementSwitch();
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.diff.engine.GenericDiffEngine#getReferencesChecker()
- */
- @Override
- protected ReferencesCheck getReferencesChecker() {
- return new UMLReferenceCheck(matchCrossReferencer);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.diff.engine.GenericDiffEngine#doDiff(org.eclipse.emf.compare.match.metamodel.MatchModel, boolean)
- */
- @Override
- public DiffModel doDiff(MatchModel match, boolean threeWay) {
- DiffModel result = super.doDiff(match, threeWay);
- return postProcess(result);
- }
-
-
- /**
- * Post process default result of Diff.
- * Processes changes stereotypes and tagged values
- *
- * @param diffModel the diff model
- * @return the diff model
- */
- protected DiffModel postProcess(DiffModel diffModel) {
- final Iterator<EObject> it = diffModel.eAllContents();
- while(it.hasNext()) {
- DiffElement diffElement = (DiffElement)it.next();
- visitElement(diffModel, diffElement);
- }
- return diffModel;
- }
-
- /**
- * Visit element.
- *
- * @param root the root
- * @param diffElement the diff element
- */
- protected void visitElement(DiffModel root, DiffElement diffElement) {
- if(diffElement instanceof DiffGroup) {
- return;
- }
- EObject stereotypeApplication = getModelElementFor(diffElement);
- if(UMLCompareUtils.isStereotypeApplication(stereotypeApplication)) {
-
- Element newVisualParent = UMLUtil.getBaseElement(stereotypeApplication);
- DiffElement newDiffParent = findOrCreateDiffElementFor(root, newVisualParent);
- AbstractDiffExtension taggedValueDiff = createDiffExtentionElementFor(diffElement);
-
- newDiffParent.getSubDiffElements().add((DiffElement)taggedValueDiff);
- hideElement(diffElement, taggedValueDiff);
- }
- }
-
- /**
- * Hide element.
- *
- * @param diffElement the diff element
- * @param diffExtension the diff extension
- */
- protected void hideElement(DiffElement diffElement, AbstractDiffExtension diffExtension) {
- if(diffExtension == null) {
- diffExtension = UMLDiffFactory.eINSTANCE.createAddStereotypeApplication();
- }
- diffExtension.getHideElements().add(diffElement);
- }
-
- /**
- * Find or create diff element for.
- *
- * @param root the root
- * @param object the object
- * @return the diff element
- */
- private DiffElement findOrCreateDiffElementFor(DiffModel root, EObject object) {
- if(object == null) {
- if(!root.getOwnedElements().isEmpty()) {
- return root.getOwnedElements().get(0);
- }
- DiffGroup diffRoot = DiffFactory.eINSTANCE.createDiffGroup();
- root.getOwnedElements().add(diffRoot);
- return diffRoot;
- }
- DiffElement element = findDiffElementFor(root, object);
- if(element != null) {
- return element;
- }
-
- DiffElement diffParent = findOrCreateDiffElementFor(root, getParent(object));
- DiffGroup diffElementForObject = DiffFactory.eINSTANCE.createDiffGroup();
- diffElementForObject.setRightParent(object);
-
- diffParent.getSubDiffElements().add(diffElementForObject);
- return diffElementForObject;
- }
-
- /**
- * Gets the parent.
- *
- * @param modelElement the model element
- * @return the parent
- */
- private EObject getParent(EObject modelElement) {
- return modelElement.eContainer();
- }
-
- /**
- * Find diff element for.
- *
- * @param root the root
- * @param modelElement the model element
- * @return the diff element
- */
- protected final DiffElement findDiffElementFor(DiffModel root, EObject modelElement) {
- if(modelElement == null) {
- return null;
- }
- final Iterator<EObject> it = root.eAllContents();
- while(it.hasNext()) {
- final DiffElement element = (DiffElement)it.next();
- if(isPertinentDiff(element, modelElement)) {
- return element;
- }
- }
- return null;
- }
-
- /**
- * Checks if is pertinent diff.
- *
- * @param diff the diff
- * @param modelElement the model element
- * @return true, if is pertinent diff
- */
- private boolean isPertinentDiff(DiffElement diff, EObject modelElement) {
- EObject domainElement = getModelElementFor(diff);
- return modelElement.equals(domainElement) || modelElement.equals(getMatchedEObject(domainElement));
- }
-
- /**
- * Gets the model element for.
- *
- * @param diff the diff
- * @return the model element for
- */
- protected EObject getModelElementFor(DiffElement diff) {
- return myGetModelElementSwitch.doSwitch(diff);
- }
-
- /**
- * Creates the diff extention element for.
- *
- * @param diffElement the diff element
- * @return the abstract diff extension
- */
- protected AbstractDiffExtension createDiffExtentionElementFor(DiffElement diffElement) {
- return myDiffElementBuilder.doSwitch(diffElement);
- }
-
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusMatchEngine.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusMatchEngine.java
deleted file mode 100644
index 329d13a..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/tatiana/PapyrusMatchEngine.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2010 CEA LIST.
- *
- *
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Tatiana Fesenko (CEA LIST) - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.tatiana;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.emf.compare.match.MatchOptions;
-import org.eclipse.emf.compare.match.engine.GenericMatchEngine;
-import org.eclipse.emf.compare.match.engine.IMatchScope;
-import org.eclipse.emf.compare.match.metamodel.MatchModel;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.resource.Resource;
-import org.eclipse.uml2.uml.Element;
-
-
-/**
- * Implementation of MatchEngine for UML Diagrams:
- * <li>Processes changes in stereotypes and tagged values as children of the base element, not of resource</li>
- */
-public class PapyrusMatchEngine extends GenericMatchEngine {
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.match.engine.GenericMatchEngine#resourceMatch(org.eclipse.emf.ecore.resource.Resource, org.eclipse.emf.ecore.resource.Resource, java.util.Map)
- */
- @Override
- public MatchModel resourceMatch(Resource leftResource, Resource rightResource, Map<String, Object> optionMap) throws InterruptedException {
- optionMap.put(MatchOptions.OPTION_MATCH_SCOPE_PROVIDER, new PapyrusMatchScopeProvider(leftResource, rightResource));
- return super.resourceMatch(leftResource, rightResource, optionMap);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.emf.compare.match.engine.GenericMatchEngine#getScopeInternalContents(org.eclipse.emf.ecore.EObject, org.eclipse.emf.compare.match.engine.IMatchScope)
- */
- @Override
- protected List<EObject> getScopeInternalContents(EObject eObject, IMatchScope scope) {
- ArrayList<EObject> result = new ArrayList<EObject>(super.getScopeInternalContents(eObject, scope));
- result.addAll(getStereotypeApplications(eObject));
- return result;
- }
-
- /**
- * Gets the stereotype applications.
- *
- * @param eObject the e object
- * @return the stereotype applications
- */
- private List<EObject> getStereotypeApplications(EObject eObject) {
- if(eObject instanceof Element) {
- return ((Element)eObject).getStereotypeApplications();
- } else {
- return Collections.emptyList();
- }
- }
-
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/PapyrusModelCompareInput.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/PapyrusModelCompareInput.java
deleted file mode 100644
index 0eecf0f..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/PapyrusModelCompareInput.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2012 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:
- * Vincent Lorenzo (CEA LIST) Vincent.Lorenzo@cea.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.utils;
-
-import java.util.List;
-
-import org.eclipse.emf.compare.diff.metamodel.ComparisonResourceSetSnapshot;
-import org.eclipse.emf.compare.diff.metamodel.ComparisonResourceSnapshot;
-import org.eclipse.emf.compare.diff.metamodel.DiffElement;
-import org.eclipse.emf.compare.diff.metamodel.DiffModel;
-import org.eclipse.emf.compare.diff.metamodel.DiffResourceSet;
-import org.eclipse.emf.compare.match.metamodel.MatchModel;
-import org.eclipse.emf.compare.match.metamodel.MatchResourceSet;
-import org.eclipse.emf.compare.ui.ICompareInputDetailsProvider;
-import org.eclipse.emf.compare.ui.ModelCompareInput;
-import org.eclipse.emf.transaction.TransactionalEditingDomain;
-import org.eclipse.papyrus.infra.emf.compare.diff.service.TransactionalMergeService;
-
-/**
- *
- * This input allows to use the Papyrus TransactionalMergeService
- *
- */
-public class PapyrusModelCompareInput extends ModelCompareInput {
-
- /**
- * The editing domain used to do the merge
- */
- final private TransactionalEditingDomain domain;
-
- /**
- *
- * Constructor.
- *
- * @param domain
- * @param matchResourceSet
- * @param diffResourceSet
- */
- public PapyrusModelCompareInput(final TransactionalEditingDomain domain, MatchResourceSet matchResourceSet, DiffResourceSet diffResourceSet) {
- super(matchResourceSet, diffResourceSet);
- this.domain = domain;
- }
-
- /**
- *
- * Constructor.
- *
- * @param domain
- * @param snapshot
- */
- public PapyrusModelCompareInput(final TransactionalEditingDomain domain, ComparisonResourceSetSnapshot snapshot) {
- super(snapshot);
- this.domain = domain;
- }
-
- /**
- *
- * Constructor.
- *
- * @param domain
- * @param snapshot
- */
- public PapyrusModelCompareInput(final TransactionalEditingDomain domain, ComparisonResourceSnapshot snapshot) {
- super(snapshot);
- this.domain = domain;
- }
-
- /**
- *
- * Constructor.
- *
- * @param domain
- * @param matchModel
- * @param diffModel
- * @param provider
- */
- public PapyrusModelCompareInput(final TransactionalEditingDomain domain, MatchModel matchModel, DiffModel diffModel, ICompareInputDetailsProvider provider) {
- super(matchModel, diffModel, provider);
- this.domain = domain;
- }
-
- /**
- *
- * Constructor.
- *
- * @param domain
- * @param matchResourceset
- * @param diffResourceSet
- * @param provider
- */
- public PapyrusModelCompareInput(final TransactionalEditingDomain domain, MatchResourceSet matchResourceset, DiffResourceSet diffResourceSet, ICompareInputDetailsProvider provider) {
- super(matchResourceset, diffResourceSet, provider);
- this.domain = domain;
- }
-
- /**
- *
- * Constructor.
- *
- * @param domain
- * @param match
- * @param diff
- */
- public PapyrusModelCompareInput(final TransactionalEditingDomain domain, MatchModel match, DiffModel diff) {
- super(match, diff);
- this.domain = domain;
- }
-
- /**
- * Applies the changes implied by a given {@link DiffElement} in the
- * direction specified by <code>leftToRight</code>.
- *
- * @param element
- * {@link DiffElement} containing the copy information.
- * @param leftToRight
- * <code>True</code> if the changes must be applied from the left
- * to the right model, <code>False</code> otherwise.
- */
- protected void doCopy(DiffElement element, boolean leftToRight) {
- TransactionalMergeService.merge(domain, element, leftToRight);
- }
-
- /**
- * Applies the changes implied by a list of {@link DiffElement} in the
- * direction specified by <code>leftToRight</code>.
- *
- * @param elements
- * {@link DiffElement}s containing the copy information.
- * @param leftToRight
- * <code>True</code> if the changes must be applied from the left
- * to the right model, <code>False</code> otherwise.
- */
- protected void doCopy(List<DiffElement> elements, boolean leftToRight) {
- TransactionalMergeService.merge(domain, elements, leftToRight);
- }
-
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/RootObject.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/RootObject.java
deleted file mode 100644
index 09e6bca..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/RootObject.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2012 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:
- * Vincent Lorenzo (CEA LIST) Vincent.Lorenzo@cea.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.utils;
-
-
-
-/**
- *
- * This class allows to recognize easily the root object in the viewer.
- * This class was introduced for comparison from the ModelExplorer
- *
- */
-public class RootObject {
-
- /**
- * the key for the left root object
- */
- public static final String LEFT_OBJECT_KEY = "leftObject";
-
- /**
- * the key for the right root object
- */
- public static final String RIGHT_OBJECT_KEY = "rightObject"; //TODO useful
-
- /** The represented object. */
- private Object representedObject = null;
-
- /**
- * Instantiates a new root object.
- *
- * @param object
- * the object
- */
- public RootObject(final Object object) {
- this.representedObject = object;
- }
-
- /**
- * Gets the represented object.
- *
- * @return the represented object
- */
- public Object getRepresentedObject() {
- return this.representedObject;
- }
-}
diff --git a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/UMLModelCompareEditorInput.java b/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/UMLModelCompareEditorInput.java
deleted file mode 100644
index b5fb8a4..0000000
--- a/deprecated/uml-compare-1.X/org.eclipse.papyrus.uml.compare/src/org/eclipse/papyrus/uml/compare/utils/UMLModelCompareEditorInput.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*****************************************************************************
- * Copyright (c) 2012 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:
- * Vincent Lorenzo (CEA LIST) Vincent.Lorenzo@cea.fr - Initial API and implementation
- *
- *****************************************************************************/
-package org.eclipse.papyrus.uml.compare.utils;
-
-import org.eclipse.compare.CompareConfiguration;
-import org.eclipse.compare.CompareViewerPane;
-import org.eclipse.emf.compare.diff.metamodel.ComparisonResourceSetSnapshot;
-import org.eclipse.emf.compare.diff.metamodel.ComparisonResourceSnapshot;
-import org.eclipse.emf.compare.diff.metamodel.ComparisonSnapshot;
-import org.eclipse.emf.compare.ui.ModelCompareInput;
-import org.eclipse.emf.compare.ui.viewer.content.ModelContentMergeViewer;
-import org.eclipse.emf.transaction.TransactionalEditingDomain;
-import org.eclipse.papyrus.infra.emf.compare.common.utils.PapyrusModelCompareEditorInput;
-import org.eclipse.papyrus.uml.compare.content.viewer.UMLTransactionalModelContentMergeViewer;
-import org.eclipse.ui.IEditorPart;
-
-/**
- *
- * The Input for the nested UMLCompareEditor
- *
- */
-public class UMLModelCompareEditorInput extends PapyrusModelCompareEditorInput {
-
- /**
- *
- * Constructor.
- *
- * @param snapshot
- * the comparison snapshot
- * @param editor
- * the editor
- */
- public UMLModelCompareEditorInput(final ComparisonSnapshot snapshot, final IEditorPart editor) {
- super(snapshot, editor);
- }
-
- /**
- *
- * @see org.eclipse.papyrus.infra.emf.compare.common.utils.PapyrusModelCompareEditorInput#createMergeViewer(org.eclipse.compare.CompareViewerPane,
- * org.eclipse.compare.CompareConfiguration)
- *
- * @param pane
- * @param config
- * @return
- */
- @Override
- protected ModelContentMergeViewer createMergeViewer(final CompareViewerPane pane, final CompareConfiguration config) {
- return new UMLTransactionalModelContentMergeViewer(pane, config, this.editor);
- }
-
- /**
- *
- * @see org.eclipse.emf.compare.ui.editor.ModelCompareEditorInput#createModelCompareInput(org.eclipse.emf.compare.diff.metamodel.ComparisonSnapshot)
- *
- * @param snap
- * @return
- */
- @Override
- protected ModelCompareInput createModelCompareInput(final ComparisonSnapshot snap) {
- final TransactionalEditingDomain domain = getEditingDomain();
- if(snap instanceof ComparisonResourceSetSnapshot) {
- return new PapyrusModelCompareInput(domain, ((ComparisonResourceSetSnapshot)snap).getMatchResourceSet(), ((ComparisonResourceSetSnapshot)snap).getDiffResourceSet());
- }
- return new PapyrusModelCompareInput(domain, ((ComparisonResourceSnapshot)snap).getMatch(), ((ComparisonResourceSnapshot)snap).getDiff());
- }
-}