diff options
author | Maged Elaasar | 2017-04-10 12:05:35 +0000 |
---|---|---|
committer | Gerrit Code Review @ Eclipse.org | 2017-04-12 08:24:04 +0000 |
commit | f5e001674caf1e7b70b1d03c9c39d4390c04514c (patch) | |
tree | 285dab0e37809f7a82827c64cfeb816fcc1f4044 /plugins/uml/architecture/org.eclipse.papyrus.uml.architecture/src | |
parent | 41e1c785d4ef6a5f5f9e827d492e86a54af00ed9 (diff) | |
download | org.eclipse.papyrus-f5e001674caf1e7b70b1d03c9c39d4390c04514c.tar.gz org.eclipse.papyrus-f5e001674caf1e7b70b1d03c9c39d4390c04514c.tar.xz org.eclipse.papyrus-f5e001674caf1e7b70b1d03c9c39d4390c04514c.zip |
Bug 510451 - Two changes: 1) Make architecture viewpoints exchangeable
between private .sash model and the public .di model, 2) Remove
PapyrusSyncTable and refactor its usage for PapyrusTable instead
Change-Id: Id5e3cfe313572e7a984dc320e868ca6ced2301c4
Signed-off-by: Maged Elaasar <melaasar@gmail.com>
Diffstat (limited to 'plugins/uml/architecture/org.eclipse.papyrus.uml.architecture/src')
-rw-r--r-- | plugins/uml/architecture/org.eclipse.papyrus.uml.architecture/src/org/eclipse/papyrus/uml/architecture/migration/UMLTableReconciler_1_3_0.java | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/plugins/uml/architecture/org.eclipse.papyrus.uml.architecture/src/org/eclipse/papyrus/uml/architecture/migration/UMLTableReconciler_1_3_0.java b/plugins/uml/architecture/org.eclipse.papyrus.uml.architecture/src/org/eclipse/papyrus/uml/architecture/migration/UMLTableReconciler_1_3_0.java index 591b999edbd..547222c77d1 100644 --- a/plugins/uml/architecture/org.eclipse.papyrus.uml.architecture/src/org/eclipse/papyrus/uml/architecture/migration/UMLTableReconciler_1_3_0.java +++ b/plugins/uml/architecture/org.eclipse.papyrus.uml.architecture/src/org/eclipse/papyrus/uml/architecture/migration/UMLTableReconciler_1_3_0.java @@ -18,12 +18,12 @@ import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.gmf.runtime.common.core.command.AbstractCommand; import org.eclipse.gmf.runtime.common.core.command.CommandResult; import org.eclipse.gmf.runtime.common.core.command.ICommand; +import org.eclipse.papyrus.infra.architecture.ArchitectureDomainManager; import org.eclipse.papyrus.infra.core.architecture.RepresentationKind; import org.eclipse.papyrus.infra.core.architecture.merged.MergedArchitectureDescriptionLanguage; -import org.eclipse.papyrus.infra.nattable.representation.PapyrusSyncTable; -import org.eclipse.papyrus.infra.architecture.ArchitectureDomainManager; import org.eclipse.papyrus.infra.nattable.common.reconciler.TableReconciler; import org.eclipse.papyrus.infra.nattable.model.nattable.Table; +import org.eclipse.papyrus.infra.nattable.representation.PapyrusTable; import org.eclipse.papyrus.uml.architecture.UMLArchitectureContextIds; /** @@ -47,17 +47,17 @@ public class UMLTableReconciler_1_3_0 extends TableReconciler { RepresentationKind newTableKind = null; if (oldTableKind != null) { if (VIEW_TABLE.equals(oldTableKind.getName())) { - newTableKind = getSyncTableKind(oldTableKind.getName(), table); + newTableKind = getTableKind(oldTableKind.getName(), table); } else if (GENERIC_TREE_TABLE.equals(oldTableKind.getName())) { - newTableKind = getSyncTableKind(oldTableKind.getName(), table); + newTableKind = getTableKind(oldTableKind.getName(), table); } else if (CLASS_TREE_TABLE.equals(oldTableKind.getName())) { - newTableKind = getSyncTableKind("Class Tree Table", table); + newTableKind = getTableKind("Class Tree Table", table); } else if (GENERIC_TABLE.equals(oldTableKind.getName())) { - newTableKind = getSyncTableKind(oldTableKind.getName(), table); + newTableKind = getTableKind(oldTableKind.getName(), table); } else if (STEREO_DISPLAY_TREE_TABLE.equals(oldTableKind.getName())) { - newTableKind = getSyncTableKind("Stereotype Display Tree Table", table); + newTableKind = getTableKind("Stereotype Display Tree Table", table); } else if (oldTableKind.getName() == null) { - newTableKind = getSyncTableKind(GENERIC_TABLE, table); + newTableKind = getTableKind(GENERIC_TABLE, table); } }; @@ -70,12 +70,12 @@ public class UMLTableReconciler_1_3_0 extends TableReconciler { /** * Get a sync table that matches the given name and that supports the given table */ - protected PapyrusSyncTable getSyncTableKind(String name, Table table) { + protected PapyrusTable getTableKind(String name, Table table) { ArchitectureDomainManager manager = ArchitectureDomainManager.getInstance(); MergedArchitectureDescriptionLanguage context = (MergedArchitectureDescriptionLanguage) manager.getArchitectureContextById(UMLArchitectureContextIds.UML); for(RepresentationKind pKind : context.getRepresentationKinds()) { if (pKind.getName().equals(name)) { - PapyrusSyncTable tKind = (PapyrusSyncTable) pKind; + PapyrusTable tKind = (PapyrusTable) pKind; if (tKind.getModelRules().get(0).getElement().isInstance(table.getContext())) { return tKind; } |