Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcletavernie2012-10-15 16:26:07 +0000
committercletavernie2012-10-15 16:26:07 +0000
commit0deece6c1f05e15594d8b111ad8d5ac12e1004ad (patch)
tree60a983e11a4284632422dede675b183846173e03 /plugins/views
parent3da13f092b20cf10f445dad148945c879057a7f5 (diff)
downloadorg.eclipse.papyrus-0deece6c1f05e15594d8b111ad8d5ac12e1004ad.tar.gz
org.eclipse.papyrus-0deece6c1f05e15594d8b111ad8d5ac12e1004ad.tar.xz
org.eclipse.papyrus-0deece6c1f05e15594d8b111ad8d5ac12e1004ad.zip
391945: [Refactoring] Part 2: Refactoring on Kepler (0.10)
https://bugs.eclipse.org/bugs/show_bug.cgi?id=391945
Diffstat (limited to 'plugins/views')
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/META-INF/MANIFEST.MF3
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/src/org/eclipse/papyrus/views/modelexplorer/resourceloading/handler/UnloadResourceHandler.java4
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/META-INF/MANIFEST.MF5
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/LinkHelper.java48
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/ModelExplorerView.java2
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/NavigatorUtils.java56
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/actions/GenericTransformer.java248
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/commands/EObjectInheritanceCopyCommand.java259
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/dnd/CommonDropAdapterAssistant.java10
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/AbstractCommandHandler.java8
-rw-r--r--plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/LoadBrowserCustomization.java120
-rw-r--r--plugins/views/properties/org.eclipse.papyrus.views.properties/META-INF/MANIFEST.MF12
12 files changed, 321 insertions, 454 deletions
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/META-INF/MANIFEST.MF b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/META-INF/MANIFEST.MF
index 1a8610e8d3a..96504e63354 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/META-INF/MANIFEST.MF
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/META-INF/MANIFEST.MF
@@ -12,7 +12,8 @@ Require-Bundle: org.eclipse.emf.converter;bundle-version="2.5.0",
org.eclipse.papyrus.infra.services.resourceloading;bundle-version="0.10.0",
org.eclipse.emf.transaction;bundle-version="1.4.0",
org.eclipse.papyrus.infra.core.log;bundle-version="0.10.0",
- org.eclipse.papyrus.infra.core;bundle-version="0.10.0"
+ org.eclipse.papyrus.infra.core;bundle-version="0.10.0",
+ org.eclipse.papyrus.infra.core.sasheditor.di;bundle-version="0.10.0"
Export-Package: org.eclipse.papyrus.views.modelexplorer.resourceloadin
g.handler
Bundle-Vendor: %providerName
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/src/org/eclipse/papyrus/views/modelexplorer/resourceloading/handler/UnloadResourceHandler.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/src/org/eclipse/papyrus/views/modelexplorer/resourceloading/handler/UnloadResourceHandler.java
index bc694ad4bc6..bbbd3bb9de7 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/src/org/eclipse/papyrus/views/modelexplorer/resourceloading/handler/UnloadResourceHandler.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer.resourceloading/src/org/eclipse/papyrus/views/modelexplorer/resourceloading/handler/UnloadResourceHandler.java
@@ -24,7 +24,7 @@ import org.eclipse.emf.common.util.URI;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.transaction.TransactionalEditingDomain;
import org.eclipse.papyrus.infra.core.resource.ModelSet;
-import org.eclipse.papyrus.infra.core.resource.notation.NotationUtils;
+import org.eclipse.papyrus.infra.core.resource.sasheditor.SashModelUtils;
import org.eclipse.papyrus.infra.services.resourceloading.util.LoadingUtils;
import org.eclipse.papyrus.views.modelexplorer.handler.AbstractCommandHandler;
import org.eclipse.ui.IEditorPart;
@@ -53,7 +53,7 @@ public class UnloadResourceHandler extends AbstractCommandHandler {
CompoundCommand command = new CompoundCommand();
List<URI> handledURI = new ArrayList<URI>();
// ensure main URI is never unloaded
- URI mainURI = NotationUtils.getNotationModel(set).getResourceURI().trimFileExtension();
+ URI mainURI = SashModelUtils.getSashModel(set).getResourceURI().trimFileExtension();
handledURI.add(mainURI);
for(EObject sel : selection) {
if(!sel.eIsProxy()) {
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/META-INF/MANIFEST.MF b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/META-INF/MANIFEST.MF
index 7995bb482eb..5c98eaada9e 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/META-INF/MANIFEST.MF
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/META-INF/MANIFEST.MF
@@ -31,7 +31,10 @@ Require-Bundle: org.eclipse.ui,
org.eclipse.gmf.runtime.diagram.ui;bundle-version="1.5.0",
org.eclipse.papyrus.infra.emf;bundle-version="0.10.0",
com.google.guava;bundle-version="10.0.1",
- org.eclipse.papyrus.infra.gmfdiag.commands;bundle-version="0.10.0"
+ org.eclipse.papyrus.infra.gmfdiag.commands;bundle-version="0.10.0",
+ org.eclipse.papyrus.infra.widgets;bundle-version="0.10.0",
+ org.eclipse.papyrus.uml.tools;bundle-version="0.10.0",
+ org.eclipse.papyrus.infra.gmfdiag.common;bundle-version="0.10.0"
Export-Package: org.eclipse.papyrus.views.modelexplorer,
org.eclipse.papyrus.views.modelexplorer.actionprovider,
org.eclipse.papyrus.views.modelexplorer.actions,
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/LinkHelper.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/LinkHelper.java
index 516c58bb5e3..e72d1ace22b 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/LinkHelper.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/LinkHelper.java
@@ -23,63 +23,67 @@ import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.ITreeSelection;
import org.eclipse.papyrus.infra.core.editor.IMultiDiagramEditor;
import org.eclipse.papyrus.infra.core.sasheditor.editor.ISashWindowsContainer;
-import org.eclipse.papyrus.infra.core.ui.IRevealSemanticElement;
import org.eclipse.papyrus.infra.core.utils.EditorUtils;
import org.eclipse.papyrus.infra.core.utils.ServiceUtils;
+import org.eclipse.papyrus.infra.widgets.util.IRevealSemanticElement;
import org.eclipse.ui.IEditorInput;
import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.ISelectionService;
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.navigator.ILinkHelper;
+
/**
* This class is to link form the model explorer to diagram
* This code was to not put in the model explorer in order to avoid dependences with gmf in the more abstract explorer
- *
+ *
*/
public class LinkHelper implements ILinkHelper {
+
/**
*
* @see org.eclipse.ui.navigator.ILinkHelper#findSelection(org.eclipse.ui.IEditorInput)
- *
+ *
*/
public IStructuredSelection findSelection(IEditorInput anInput) {
return null;
}
+
/**
*
* @see org.eclipse.ui.navigator.ILinkHelper#activateEditor(org.eclipse.ui.IWorkbenchPage, org.eclipse.jface.viewers.IStructuredSelection)
- *
+ *
*/
public void activateEditor(IWorkbenchPage aPage, IStructuredSelection aSelection) {
//no selection
- if (aSelection == null || aSelection.isEmpty())
+ if(aSelection == null || aSelection.isEmpty()) {
return;
- ISelectionService selectService=aPage.getWorkbenchWindow().getSelectionService();
- ISelection selection=selectService.getSelection();
+ }
+ ISelectionService selectService = aPage.getWorkbenchWindow().getSelectionService();
+ ISelection selection = selectService.getSelection();
//test if the selection come the tree viewer in order to avoid cycle: Diagram -> tree-> diagram
// if the diagram has been selected the selection is not a TreeSelection
- if( selection instanceof ITreeSelection){
- IMultiDiagramEditor papyrusEditor=EditorUtils.getMultiDiagramEditor();
+ if(selection instanceof ITreeSelection) {
+ IMultiDiagramEditor papyrusEditor = EditorUtils.getMultiDiagramEditor();
+
-
try {
- ISashWindowsContainer windowsContainer=ServiceUtils.getInstance().getISashWindowsContainer(papyrusEditor.getServicesRegistry());
+ ISashWindowsContainer windowsContainer = ServiceUtils.getInstance().getISashWindowsContainer(papyrusEditor.getServicesRegistry());
- Iterator<IEditorPart>iterPart=windowsContainer.getVisibleIEditorParts().iterator();
+ Iterator<IEditorPart> iterPart = windowsContainer.getVisibleIEditorParts().iterator();
- while(iterPart.hasNext()){
- IEditorPart diagramEditor=iterPart.next();
- if (diagramEditor instanceof IRevealSemanticElement){
- if( aSelection instanceof IStructuredSelection){
- Iterator<?> selectionIterator=((IStructuredSelection)aSelection).iterator();
- ArrayList<Object> semanticElementList= new ArrayList<Object>();
+ while(iterPart.hasNext()) {
+ IEditorPart diagramEditor = iterPart.next();
+ if(diagramEditor instanceof IRevealSemanticElement) {
+ if(aSelection instanceof IStructuredSelection) {
+ Iterator<?> selectionIterator = aSelection.iterator();
+ ArrayList<Object> semanticElementList = new ArrayList<Object>();
while(selectionIterator.hasNext()) {
- Object currentSelection = (Object)selectionIterator.next();
- if( currentSelection instanceof IAdaptable){
- Object semanticElement=((IAdaptable)currentSelection).getAdapter(EObject.class);
- if( semanticElement!=null){
+ Object currentSelection = selectionIterator.next();
+ if(currentSelection instanceof IAdaptable) {
+ Object semanticElement = ((IAdaptable)currentSelection).getAdapter(EObject.class);
+ if(semanticElement != null) {
semanticElementList.add(semanticElement);
}
}
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/ModelExplorerView.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/ModelExplorerView.java
index 1b013dbe407..8681d76ab8a 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/ModelExplorerView.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/ModelExplorerView.java
@@ -51,10 +51,10 @@ import org.eclipse.papyrus.infra.core.resource.additional.AdditionalResourcesMod
import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IPageMngr;
import org.eclipse.papyrus.infra.core.services.ServiceException;
import org.eclipse.papyrus.infra.core.services.ServicesRegistry;
-import org.eclipse.papyrus.infra.core.ui.IRevealSemanticElement;
import org.eclipse.papyrus.infra.core.utils.EditorUtils;
import org.eclipse.papyrus.infra.core.utils.ServiceUtils;
import org.eclipse.papyrus.infra.emf.providers.SemanticFromModelExplorer;
+import org.eclipse.papyrus.infra.widgets.util.IRevealSemanticElement;
import org.eclipse.papyrus.views.modelexplorer.listener.DoubleClickListener;
import org.eclipse.papyrus.views.modelexplorer.matching.IMatchingItem;
import org.eclipse.papyrus.views.modelexplorer.matching.LinkItemMatchingItem;
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/NavigatorUtils.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/NavigatorUtils.java
index b2611416698..26573c032fa 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/NavigatorUtils.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/NavigatorUtils.java
@@ -20,6 +20,7 @@ import org.eclipse.gmf.runtime.notation.NotationPackage;
import org.eclipse.gmf.runtime.notation.View;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.papyrus.infra.emf.utils.EMFHelper;
import org.eclipse.ui.IViewPart;
import org.eclipse.ui.IViewReference;
import org.eclipse.ui.IWorkbenchPage;
@@ -69,26 +70,6 @@ public class NavigatorUtils {
}
/**
- * Resolve semantic element
- *
- * @param object
- * the object to resolve
- * @return <code>null</code> or the semantic element associated to the
- * specified object
- */
- public static EObject resolveSemanticObject(Object object) {
- if(object instanceof EObject) {
- return (EObject)object;
- } else if(object instanceof IAdaptable) {
- IAdaptable adaptable = (IAdaptable)object;
- if(adaptable.getAdapter(EObject.class) != null) {
- return (EObject)adaptable.getAdapter(EObject.class);
- }
- }
- return null;
- }
-
- /**
* Unwraps selection. Gets <EObject>s from <EditPart>s, from <View>s or from
* <EObject>s
*
@@ -120,7 +101,7 @@ public class NavigatorUtils {
selectionList.add(element);
}
}
- EObject eObject = NavigatorUtils.resolveSemanticObject(next);
+ EObject eObject = EMFHelper.getEObject(next);
if(eObject != null) {
selectionList.add(eObject);
}
@@ -294,54 +275,49 @@ public class NavigatorUtils {
if(result == null) {
result = (T)Platform.getAdapterManager().getAdapter(o, theClass);
}
- if (result == null && theClass.isInstance(o))
- {
- result = (T)o ;
+ if(result == null && theClass.isInstance(o)) {
+ result = (T)o;
}
return result;
}
-
+
/**
* Search all the elements referencing the context,
- * filter the results by the predicate
+ * filter the results by the predicate
+ *
* @return
*/
- public static boolean find (EObject toFind, Predicate<Setting> predicate)
- {
- if (toFind == null || toFind.eResource() == null || toFind.eResource().getResourceSet() == null)
- {
+ public static boolean find(EObject toFind, Predicate<Setting> predicate) {
+ if(toFind == null || toFind.eResource() == null || toFind.eResource().getResourceSet() == null) {
return false;
}
ResourceSet resourceSet = toFind.eResource().getResourceSet();
ECrossReferenceAdapter adapter = ECrossReferenceAdapter.getCrossReferenceAdapter(resourceSet);
- if (adapter == null)
- {
+ if(adapter == null) {
adapter = new ECrossReferenceAdapter();
resourceSet.eAdapters().add(adapter);
}
Collection<Setting> settings = adapter.getInverseReferences(toFind, false);
return Iterables.filter(settings, predicate).iterator().hasNext();
}
-
+
/**
* Search all the elements referencing the context,
* filter the results by the predicate and apply the function to return the desired types
+ *
* @return
*/
- public static <T> Collection<T> findFilterAndApply (EObject toFind, Predicate<Setting> predicate, Function<Setting,T> function)
- {
- if (toFind == null || toFind.eResource() == null || toFind.eResource().getResourceSet() == null)
- {
+ public static <T> Collection<T> findFilterAndApply(EObject toFind, Predicate<Setting> predicate, Function<Setting, T> function) {
+ if(toFind == null || toFind.eResource() == null || toFind.eResource().getResourceSet() == null) {
return Collections.emptyList();
}
ResourceSet resourceSet = toFind.eResource().getResourceSet();
ECrossReferenceAdapter adapter = ECrossReferenceAdapter.getCrossReferenceAdapter(resourceSet);
- if (adapter == null)
- {
+ if(adapter == null) {
adapter = new ECrossReferenceAdapter();
resourceSet.eAdapters().add(adapter);
}
Collection<Setting> settings = adapter.getInverseReferences(toFind, false);
- return Lists.newLinkedList(Iterables.transform(Iterables.filter(settings, predicate),function));
+ return Lists.newLinkedList(Iterables.transform(Iterables.filter(settings, predicate), function));
}
}
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/actions/GenericTransformer.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/actions/GenericTransformer.java
index 5f8e6f66c35..f56765a31ef 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/actions/GenericTransformer.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/actions/GenericTransformer.java
@@ -68,7 +68,7 @@ import org.eclipse.gmf.runtime.notation.NotationPackage;
import org.eclipse.gmf.runtime.notation.View;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.papyrus.infra.core.utils.EditorUtils;
-import org.eclipse.papyrus.infra.core.utils.PapyrusEcoreUtils;
+import org.eclipse.papyrus.infra.emf.utils.EMFHelper;
import org.eclipse.papyrus.views.modelexplorer.Activator;
import org.eclipse.papyrus.views.modelexplorer.commands.EObjectInheritanceCopyCommand;
import org.eclipse.swt.widgets.Display;
@@ -116,7 +116,7 @@ public class GenericTransformer {
* Instantiates a new generic transformer.
*
* @param currentNode
- * the current node
+ * the current node
*/
public GenericTransformer(AbstractGraphicalEditPart currentNode) {
this(currentNode, true);
@@ -127,17 +127,16 @@ public class GenericTransformer {
* graphical copy
*
* @param currentNode
- * the current node
+ * the current node
* @param graphCopy
- * the graph copy
+ * the graph copy
*/
- public GenericTransformer(AbstractGraphicalEditPart currentNode,
- boolean graphCopy) {
+ public GenericTransformer(AbstractGraphicalEditPart currentNode, boolean graphCopy) {
this.graphCopy = graphCopy;
- if (currentNode != null) {
+ if(currentNode != null) {
Object model = currentNode.getModel();
- if (model instanceof View) {
- this.element = ((View) model).getElement();
+ if(model instanceof View) {
+ this.element = ((View)model).getElement();
}
}
}
@@ -146,7 +145,7 @@ public class GenericTransformer {
* Instantiates a new generic transformer.
*
* @param currentEobject
- * the current eobject
+ * the current eobject
*/
public GenericTransformer(EObject currentEobject) {
this.element = currentEobject;
@@ -156,65 +155,54 @@ public class GenericTransformer {
* Transform the element to the given eclass.
*
* @param eclass
- * the targeted eclass
+ * the targeted eclass
*/
public void transform(EClass eclass) {
- IWorkbenchPage page = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getActivePage();
+ IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
IEditorPart editor = page.getActiveEditor();
- CommandStack stack = (CommandStack) editor
- .getAdapter(CommandStack.class);
+ CommandStack stack = (CommandStack)editor.getAdapter(CommandStack.class);
globalCommand = new CompositeCommand("Generic Transformation");
- if (graphCopy) {
- if (element != null) {
- EReference[] features = { NotationPackage.eINSTANCE
- .getView_Element() };
- Collection<?> views = EMFCoreUtil.getReferencers(element,
- features);
- for (Object view : views) {
- if (view instanceof View) {
- referencingViews.add((View) view);
+ if(graphCopy) {
+ if(element != null) {
+ EReference[] features = { NotationPackage.eINSTANCE.getView_Element() };
+ Collection<?> views = EMFCoreUtil.getReferencers(element, features);
+ for(Object view : views) {
+ if(view instanceof View) {
+ referencingViews.add((View)view);
}
}
}
}
- if (stack != null) {
+ if(stack != null) {
// maybe extension point for stereotypes
- EObject model = (EObject) AdapterFactoryEditingDomain
- .unwrap(element);
+ EObject model = (EObject)AdapterFactoryEditingDomain.unwrap(element);
// get mixed editing domain to do transaction
- TransactionalEditingDomain domain = EditorUtils
- .getTransactionalEditingDomain();
- commandModel = new EObjectInheritanceCopyCommand(model, eclass,
- domain);
+ TransactionalEditingDomain domain = EditorUtils.getTransactionalEditingDomain();
+ commandModel = new EObjectInheritanceCopyCommand(model, eclass, domain);
globalCommand.add(commandModel);
- if (graphCopy) {
+ if(graphCopy) {
importerCommand = new ImporterCommand(domain);
- if (importerCommand.canExecute()) {
+ if(importerCommand.canExecute()) {
globalCommand.add(importerCommand);
}
}
- if (globalCommand.canExecute()) {
+ if(globalCommand.canExecute()) {
try {
// drop caches about input element
- ECrossReferenceAdapter cross = ECrossReferenceAdapter
- .getCrossReferenceAdapter(element);
- if (cross != null) {
+ ECrossReferenceAdapter cross = ECrossReferenceAdapter.getCrossReferenceAdapter(element);
+ if(cross != null) {
cross.unsetTarget(element);
}
stack.execute(new ICommandProxy(globalCommand));
} catch (Exception e) {
- MessageDialog.openWarning(Display.getDefault()
- .getActiveShell(), WARNING_TITLE, WARNING_MSG);
+ MessageDialog.openWarning(Display.getDefault().getActiveShell(), WARNING_TITLE, WARNING_MSG);
e.printStackTrace();
}
} else {
- MessageDialog.openWarning(
- Display.getDefault().getActiveShell(), WARNING_TITLE,
- WARNING_MSG);
+ MessageDialog.openWarning(Display.getDefault().getActiveShell(), WARNING_TITLE, WARNING_MSG);
}
}
}
@@ -229,7 +217,7 @@ public class GenericTransformer {
* Constructor.
*
* @param domain
- * transactional editing domain
+ * transactional editing domain
*/
public ImporterCommand(TransactionalEditingDomain domain) {
super(domain, "Import graphical nodes", null);
@@ -239,14 +227,14 @@ public class GenericTransformer {
* Execute the command
*
* @param monitor
- * progress monitor
+ * progress monitor
* @param info
- * the info
+ * the info
* @return the command result
* @throws ExecutionException
*/
- protected CommandResult doExecuteWithResult(IProgressMonitor monitor,
- IAdaptable info) throws ExecutionException {
+ @Override
+ protected CommandResult doExecuteWithResult(IProgressMonitor monitor, IAdaptable info) throws ExecutionException {
graphCopy(null, commandModel.getResultEobject());
return CommandResult.newOKCommandResult();
}
@@ -255,102 +243,85 @@ public class GenericTransformer {
* Graph copy, make a drag and drop of the new object on all diagrams
*
* @param diagramDomain
- * the mixed domain
+ * the mixed domain
* @param target
- * the target
+ * the target
* @param globalCommand2
* @param graphElement
- * the graph element
+ * the graph element
* @param oldLocation
- * the old location
+ * the old location
* @param editpart
- * the editpart
+ * the editpart
*/
private void graphCopy(IDiagramEditDomain domain, EObject target) {
- for (View graphElement : referencingViews) {
+ for(View graphElement : referencingViews) {
View parent = ViewUtil.getContainerView(graphElement);
- if (parent == null || graphElement.getDiagram() == null) {
+ if(parent == null || graphElement.getDiagram() == null) {
// this is an orphaned view. Skip it
continue;
}
- IWorkbenchPage page = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getActivePage();
+ IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
// Get the edit part of the diagram containing the view.
DiagramEditPart diagramEditPart = null;
IEditorPart activeEditorPart = page.getActiveEditor();
- if (activeEditorPart instanceof IDiagramWorkbenchPart) {
- if (graphElement.getDiagram().equals(
- ((IDiagramWorkbenchPart) activeEditorPart)
- .getDiagram())) {
- diagramEditPart = ((IDiagramWorkbenchPart) activeEditorPart)
- .getDiagramEditPart();
+ if(activeEditorPart instanceof IDiagramWorkbenchPart) {
+ if(graphElement.getDiagram().equals(((IDiagramWorkbenchPart)activeEditorPart).getDiagram())) {
+ diagramEditPart = ((IDiagramWorkbenchPart)activeEditorPart).getDiagramEditPart();
}
}
- if (diagramEditPart == null) {
+ if(diagramEditPart == null) {
// search in other editor parts than the active one
- List<?> editorParts = EditorService.getInstance()
- .getRegisteredEditorParts();
- for (Object editorPart : editorParts) {
- if (editorPart instanceof IDiagramWorkbenchPart) {
- if (graphElement.getDiagram().equals(
- ((IDiagramWorkbenchPart) editorPart)
- .getDiagram())) {
- diagramEditPart = ((IDiagramWorkbenchPart) editorPart)
- .getDiagramEditPart();
+ List<?> editorParts = EditorService.getInstance().getRegisteredEditorParts();
+ for(Object editorPart : editorParts) {
+ if(editorPart instanceof IDiagramWorkbenchPart) {
+ if(graphElement.getDiagram().equals(((IDiagramWorkbenchPart)editorPart).getDiagram())) {
+ diagramEditPart = ((IDiagramWorkbenchPart)editorPart).getDiagramEditPart();
}
}
}
}
- if (diagramEditPart != null) {
- EditPart containerPart = (EditPart) diagramEditPart
- .getViewer().getEditPartRegistry().get(parent);
+ if(diagramEditPart != null) {
+ EditPart containerPart = (EditPart)diagramEditPart.getViewer().getEditPartRegistry().get(parent);
// create the new transformed view
DropObjectsRequest req = new DropObjectsRequest();
req.setObjects(Collections.singletonList(target));
- if (graphElement instanceof Node) {
- LayoutConstraint constraint = ((Node) graphElement)
- .getLayoutConstraint();
- if (constraint instanceof Location) {
- Location location = (Location) constraint;
- req.setLocation(new Point(location.getX(), location
- .getY()));
+ if(graphElement instanceof Node) {
+ LayoutConstraint constraint = ((Node)graphElement).getLayoutConstraint();
+ if(constraint instanceof Location) {
+ Location location = (Location)constraint;
+ req.setLocation(new Point(location.getX(), location.getY()));
}
}
- if (req.getLocation() == null) {
+ if(req.getLocation() == null) {
req.setLocation(new Point());
}
Command partCreationCmd = containerPart.getCommand(req);
partCreationCmd.execute();
View newView = null;
- if (partCreationCmd instanceof ICommandProxy) {
- CommandResult res = ((ICommandProxy) partCreationCmd)
- .getICommand().getCommandResult();
+ if(partCreationCmd instanceof ICommandProxy) {
+ CommandResult res = ((ICommandProxy)partCreationCmd).getICommand().getCommandResult();
Object newValue = res.getReturnValue();
- if (newValue instanceof Collection<?>) {
- for (Object value : (Collection<?>) newValue) {
- if (value instanceof ViewDescriptor) {
- newView = (View) ((ViewDescriptor) value)
- .getAdapter(View.class);
+ if(newValue instanceof Collection<?>) {
+ for(Object value : (Collection<?>)newValue) {
+ if(value instanceof ViewDescriptor) {
+ newView = (View)((ViewDescriptor)value).getAdapter(View.class);
}
}
- } else if (newValue instanceof ViewDescriptor) {
- newView = (View) ((ViewDescriptor) newValue)
- .getAdapter(View.class);
+ } else if(newValue instanceof ViewDescriptor) {
+ newView = (View)((ViewDescriptor)newValue).getAdapter(View.class);
}
}
// with ViewRefactorHelper, copy view properties on the old
// one
- if (newView != null) {
- ViewTransformerHelper helper = new ViewTransformerHelper(
- diagramEditPart.getDiagramPreferencesHint());
+ if(newView != null) {
+ ViewTransformerHelper helper = new ViewTransformerHelper(diagramEditPart.getDiagramPreferencesHint());
helper.copyMixedViewFeatures(graphElement, newView);
}
// delete the old view
- GroupRequest deleteReq = new GroupRequest(
- RequestConstants.REQ_DELETE);
- EditPart oldPart = (EditPart) diagramEditPart.getViewer()
- .getEditPartRegistry().get(graphElement);
+ GroupRequest deleteReq = new GroupRequest(RequestConstants.REQ_DELETE);
+ EditPart oldPart = (EditPart)diagramEditPart.getViewer().getEditPartRegistry().get(graphElement);
Command partDeletionCmd = oldPart.getCommand(deleteReq);
partDeletionCmd.execute();
}
@@ -370,7 +341,7 @@ public class GenericTransformer {
* Constructor.
*
* @param preferencesHint
- * the diagram preferences hint
+ * the diagram preferences hint
*/
public ViewTransformerHelper(PreferencesHint preferencesHint) {
super(preferencesHint);
@@ -380,17 +351,17 @@ public class GenericTransformer {
* Copy common features from a view to another
*
* @param oldView
- * the old view to copy from
+ * the old view to copy from
* @param newView
- * the new view to copy to
+ * the new view to copy to
*/
public void copyMixedViewFeatures(View oldView, View newView) {
- if (oldView instanceof Diagram && newView instanceof Diagram) {
- copyDiagramFeatures((Diagram) oldView, (Diagram) newView);
- } else if (oldView instanceof Node && newView instanceof Node) {
- copyNodeFeatures((Node) oldView, (Node) newView);
- } else if (oldView instanceof Edge && newView instanceof Edge) {
- copyEdgeFeatures((Edge) oldView, (Edge) newView);
+ if(oldView instanceof Diagram && newView instanceof Diagram) {
+ copyDiagramFeatures((Diagram)oldView, (Diagram)newView);
+ } else if(oldView instanceof Node && newView instanceof Node) {
+ copyNodeFeatures((Node)oldView, (Node)newView);
+ } else if(oldView instanceof Edge && newView instanceof Edge) {
+ copyEdgeFeatures((Edge)oldView, (Edge)newView);
} else {
copyViewFeatures(oldView, newView);
}
@@ -402,7 +373,7 @@ public class GenericTransformer {
* Gets all the super types.
*
* @param class1
- * the class
+ * the class
*
* @return super types
*/
@@ -416,22 +387,19 @@ public class GenericTransformer {
* Gets the factory from uri.
*
* @param uri
- * the uri
+ * the uri
*
* @return the factory
*/
public static AdapterFactory getFactory(String uri) {
AdapterFactory factory = factories.get(uri);
- if (factory == null) {
- IConfigurationElement[] extensions = Platform
- .getExtensionRegistry().getConfigurationElementsFor(
- EXT_FACTORIES);
- for (IConfigurationElement e : extensions) {
- if (uri.equals(e.getAttribute("uri"))) {
+ if(factory == null) {
+ IConfigurationElement[] extensions = Platform.getExtensionRegistry().getConfigurationElementsFor(EXT_FACTORIES);
+ for(IConfigurationElement e : extensions) {
+ if(uri.equals(e.getAttribute("uri"))) {
try {
- factory = (AdapterFactory) e
- .createExecutableExtension("class");
- if (factory != null) {
+ factory = (AdapterFactory)e.createExecutableExtension("class");
+ if(factory != null) {
factories.put(uri, factory);
}
} catch (CoreException e1) {
@@ -447,36 +415,22 @@ public class GenericTransformer {
* Checks if a transformation is possible.
*
* @param eclass
- * the eclass
+ * the eclass
*
* @return the multi status
*/
public MultiStatus isTransformationPossible(EClass eclass) {
- MultiStatus result = new MultiStatus(Activator.PLUGIN_ID, 0,
- "Type incompatibility", null);
- if (element != null) {
- Collection<Setting> usages = PapyrusEcoreUtils.getUsages(element);
- if (usages != null) {
- for (EStructuralFeature.Setting nonNavigableInverseReference : usages) {
- EStructuralFeature structuralFeature = nonNavigableInverseReference
- .getEStructuralFeature();
- if (!(nonNavigableInverseReference.getEObject() instanceof View)) {
- boolean compatible = EObjectInheritanceCopyCommand
- .isCompatible(structuralFeature.getEType(),
- eclass);
- if (!compatible) {
- String econtainer = structuralFeature.eContainer() instanceof EClassifier ? ((EClassifier) structuralFeature
- .eContainer()).getName()
- + " ( "
- + nonNavigableInverseReference.getEObject()
- .toString() + " )"
- : structuralFeature.eContainer().toString();
- Status s = new Status(
- Status.WARNING,
- Activator.PLUGIN_ID,
- String.format(
- "an element typed %s references your selection, we can not assign instead of your selection an object typed %s",
- econtainer, eclass.getName()));
+ MultiStatus result = new MultiStatus(Activator.PLUGIN_ID, 0, "Type incompatibility", null);
+ if(element != null) {
+ Collection<Setting> usages = EMFHelper.getUsages(element);
+ if(usages != null) {
+ for(EStructuralFeature.Setting nonNavigableInverseReference : usages) {
+ EStructuralFeature structuralFeature = nonNavigableInverseReference.getEStructuralFeature();
+ if(!(nonNavigableInverseReference.getEObject() instanceof View)) {
+ boolean compatible = EObjectInheritanceCopyCommand.isCompatible(structuralFeature.getEType(), eclass);
+ if(!compatible) {
+ String econtainer = structuralFeature.eContainer() instanceof EClassifier ? ((EClassifier)structuralFeature.eContainer()).getName() + " ( " + nonNavigableInverseReference.getEObject().toString() + " )" : structuralFeature.eContainer().toString();
+ Status s = new Status(Status.WARNING, Activator.PLUGIN_ID, String.format("an element typed %s references your selection, we can not assign instead of your selection an object typed %s", econtainer, eclass.getName()));
result.add(s);
}
}
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/commands/EObjectInheritanceCopyCommand.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/commands/EObjectInheritanceCopyCommand.java
index 60499320b7c..fd9e97e9d79 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/commands/EObjectInheritanceCopyCommand.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/commands/EObjectInheritanceCopyCommand.java
@@ -36,7 +36,7 @@ import org.eclipse.gmf.runtime.emf.type.core.requests.SetRequest;
import org.eclipse.gmf.runtime.notation.Diagram;
import org.eclipse.gmf.runtime.notation.View;
import org.eclipse.papyrus.commands.DestroyElementPapyrusCommand;
-import org.eclipse.papyrus.infra.core.utils.PapyrusEcoreUtils;
+import org.eclipse.papyrus.infra.emf.utils.EMFHelper;
/**
* The Class EObjectInheritanceCopyCommand. it takes an eobject in parameter and
@@ -53,28 +53,20 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
private Collection<Object> alreadyManaged = new LinkedList<Object>();
- public EObjectInheritanceCopyCommand(EObject source, EClass target,
- TransactionalEditingDomain adapterFactoryEditingDomain) {
+ public EObjectInheritanceCopyCommand(EObject source, EClass target, TransactionalEditingDomain adapterFactoryEditingDomain) {
super("Inheritance copy");
this.sourceEObject = source;
- this.targetEObject = target.getEPackage().getEFactoryInstance().create(
- target);
+ this.targetEObject = target.getEPackage().getEFactoryInstance().create(target);
this.editingDomain = adapterFactoryEditingDomain;
- if (sourceEObject == null || targetEObject == null
- || editingDomain == null) {
- throw new IllegalArgumentException(
- "Please provide non null arguments");
+ if(sourceEObject == null || targetEObject == null || editingDomain == null) {
+ throw new IllegalArgumentException("Please provide non null arguments");
}
init();
- if (sourceEObject.eContainingFeature().isMany()) {
- replace(sourceEObject.eContainer(), sourceEObject, targetEObject,
- sourceEObject.eContainingFeature());
+ if(sourceEObject.eContainingFeature().isMany()) {
+ replace(sourceEObject.eContainer(), sourceEObject, targetEObject, sourceEObject.eContainingFeature());
} else {
- add(new CustomSetCommand(editingDomain, sourceEObject.eContainer(),
- sourceEObject.eContainingFeature(), targetEObject,
- sourceEObject, sourceEObject.eContainingFeature()));
- add(new DestroyElementPapyrusCommand(new DestroyElementRequest(
- editingDomain, sourceEObject, false)));
+ add(new CustomSetCommand(editingDomain, sourceEObject.eContainer(), sourceEObject.eContainingFeature(), targetEObject, sourceEObject, sourceEObject.eContainingFeature()));
+ add(new DestroyElementPapyrusCommand(new DestroyElementRequest(editingDomain, sourceEObject, false)));
}
}
@@ -87,21 +79,18 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
* Model copy, copy the eobject source attributes to target's
*
* @param mixedDomain
- * the mixed domain
+ * the mixed domain
* @param source
- * the source
+ * the source
* @param target
- * the target
+ * the target
*/
private void modelCopy(EObject source, EObject target) {
EClass eclass = source.eClass();
- if (eclass != null) {
- EList<EStructuralFeature> eAllStructuralFeatures = eclass
- .getEAllStructuralFeatures();
- for (EStructuralFeature e : eAllStructuralFeatures) {
- if (contains(target.eClass(), e)
- && isCompatible(e.getEType(), target.eClass()
- .getEStructuralFeature(e.getName()).getEType())) {
+ if(eclass != null) {
+ EList<EStructuralFeature> eAllStructuralFeatures = eclass.getEAllStructuralFeatures();
+ for(EStructuralFeature e : eAllStructuralFeatures) {
+ if(contains(target.eClass(), e) && isCompatible(e.getEType(), target.eClass().getEStructuralFeature(e.getName()).getEType())) {
manageFeature(source, target, e);
}
}
@@ -113,16 +102,16 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
* the same name less rigorous can work for many cases
*
* @param target
- * the target
+ * the target
* @param e
- * the e
+ * the e
*
* @return true, if successful
*/
private boolean contains(EClass target, EStructuralFeature e) {
EList<EStructuralFeature> features = target.getEAllStructuralFeatures();
- for (EStructuralFeature f : features) {
- if (f.getName().equals(e.getName())) {
+ for(EStructuralFeature f : features) {
+ if(f.getName().equals(e.getName())) {
return true;
}
}
@@ -133,96 +122,79 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
* Manage feature for cross.
*
* @param mixedDomain
- * the mixed domain
+ * the mixed domain
* @param theObjectWithCross
- * the the object with cross
+ * the the object with cross
* @param source
- * the source
+ * the source
* @param target
- * the target
+ * the target
* @param structuralFeature
- * the structural feature
+ * the structural feature
*/
- private void manageFeatureForCross(EObject theObjectWithCross,
- EObject source, EObject target, EStructuralFeature structuralFeature) {
- boolean compatible = isCompatible(structuralFeature.getEType(), target
- .eClass());
-
- if (compatible && structuralFeature.isChangeable()
- && !structuralFeature.isDerived()) {
- if (structuralFeature.isMany()) {
+ private void manageFeatureForCross(EObject theObjectWithCross, EObject source, EObject target, EStructuralFeature structuralFeature) {
+ boolean compatible = isCompatible(structuralFeature.getEType(), target.eClass());
+
+ if(compatible && structuralFeature.isChangeable() && !structuralFeature.isDerived()) {
+ if(structuralFeature.isMany()) {
replace(theObjectWithCross, source, target, structuralFeature);
} else {
- add(new SetValueCommand(new SetRequest(editingDomain,
- theObjectWithCross, structuralFeature, target)));
+ add(new SetValueCommand(new SetRequest(editingDomain, theObjectWithCross, structuralFeature, target)));
}
- } else if (!compatible) {
- if (structuralFeature.isMany()) {
+ } else if(!compatible) {
+ if(structuralFeature.isMany()) {
remove(theObjectWithCross, source, structuralFeature);
} else {
- add(new SetValueCommand(new SetRequest(editingDomain,
- theObjectWithCross, structuralFeature, null)));
+ add(new SetValueCommand(new SetRequest(editingDomain, theObjectWithCross, structuralFeature, null)));
}
}
}
- private void remove(EObject owner, Object source,
- EStructuralFeature structuralFeature) {
- if (!alreadyManaged.contains(source)) {
+ private void remove(EObject owner, Object source, EStructuralFeature structuralFeature) {
+ if(!alreadyManaged.contains(source)) {
- if (owner == null && structuralFeature == null) {
- if (source instanceof EObject) {
- add(new DestroyElementPapyrusCommand(new DestroyElementRequest(
- editingDomain, (EObject) source, false)));
+ if(owner == null && structuralFeature == null) {
+ if(source instanceof EObject) {
+ add(new DestroyElementPapyrusCommand(new DestroyElementRequest(editingDomain, (EObject)source, false)));
}
} else {
Object value = owner.eGet(structuralFeature);
- if (value instanceof Collection<?>) {
- List<Object> newList = new ArrayList<Object>(
- (Collection<?>) value);
+ if(value instanceof Collection<?>) {
+ List<Object> newList = new ArrayList<Object>((Collection<?>)value);
newList.remove(source);
- add(new SetValueCommand(new SetRequest(editingDomain,
- owner, structuralFeature, newList)));
- } else if (source.equals(value)) {
- add(new SetValueCommand(new SetRequest(editingDomain,
- owner, structuralFeature, null)));
+ add(new SetValueCommand(new SetRequest(editingDomain, owner, structuralFeature, newList)));
+ } else if(source.equals(value)) {
+ add(new SetValueCommand(new SetRequest(editingDomain, owner, structuralFeature, null)));
} else {
- add(new SetValueCommand(new SetRequest(editingDomain,
- owner, structuralFeature, null)));
+ add(new SetValueCommand(new SetRequest(editingDomain, owner, structuralFeature, null)));
}
}
alreadyManaged.add(source);
}
}
- private void replace(EObject owner, Object source, Object target,
- EStructuralFeature structuralFeature) {
- if (!alreadyManaged.contains(source)) {
+ private void replace(EObject owner, Object source, Object target, EStructuralFeature structuralFeature) {
+ if(!alreadyManaged.contains(source)) {
- if (owner == null && structuralFeature == null) {
- if (source instanceof EObject) {
- add(new DestroyElementPapyrusCommand(new DestroyElementRequest(
- editingDomain, (EObject) source, false)));
+ if(owner == null && structuralFeature == null) {
+ if(source instanceof EObject) {
+ add(new DestroyElementPapyrusCommand(new DestroyElementRequest(editingDomain, (EObject)source, false)));
}
} else {
Object value = owner.eGet(structuralFeature);
- if (value instanceof Collection<?>) {
- List<Object> newList = new ArrayList<Object>(
- (Collection<?>) value);
+ if(value instanceof Collection<?>) {
+ List<Object> newList = new ArrayList<Object>((Collection<?>)value);
int index = newList.indexOf(source);
- if (index >= 0) {
+ if(index >= 0) {
newList.remove(index);
newList.add(index, target);
- add(new SetValueCommand(new SetRequest(editingDomain,
- owner, structuralFeature, newList)));
+ add(new SetValueCommand(new SetRequest(editingDomain, owner, structuralFeature, newList)));
}
- } else if (source.equals(value)) {
- add(new SetValueCommand(new SetRequest(editingDomain,
- owner, structuralFeature, target)));
+ } else if(source.equals(value)) {
+ add(new SetValueCommand(new SetRequest(editingDomain, owner, structuralFeature, target)));
} else {
- add(new SetValueCommand(new SetRequest(editingDomain,
- owner, structuralFeature, target)));
+ add(new SetValueCommand(new SetRequest(editingDomain, owner, structuralFeature, target)));
}
}
alreadyManaged.add(source);
@@ -230,8 +202,7 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
}
@Override
- public IStatus undo(IProgressMonitor progressMonitor, IAdaptable info)
- throws ExecutionException {
+ public IStatus undo(IProgressMonitor progressMonitor, IAdaptable info) throws ExecutionException {
return super.undo(progressMonitor, info);
}
@@ -239,24 +210,21 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
* Cross reference. Manage eobjects referencing the source eobject
*
* @param mixedDomain
- * the mixed domain
+ * the mixed domain
* @param source
- * the source eobject
+ * the source eobject
* @param target
- * the target eobject
+ * the target eobject
*/
private void crossReference(EObject source, EObject target) {
- Collection<EStructuralFeature.Setting> collection = PapyrusEcoreUtils.getUsages(source);
- if (collection != null) {
- for (EStructuralFeature.Setting nonNavigableInverseReference : collection) {
- EStructuralFeature structuralFeature = nonNavigableInverseReference
- .getEStructuralFeature();
- if (!(nonNavigableInverseReference.getEObject() instanceof View)) {
- manageFeatureForCross(nonNavigableInverseReference
- .getEObject(), source, target, structuralFeature);
- } else if (nonNavigableInverseReference.getEObject() instanceof Diagram) {
- Diagram di = (Diagram) nonNavigableInverseReference
- .getEObject();
+ Collection<EStructuralFeature.Setting> collection = EMFHelper.getUsages(source);
+ if(collection != null) {
+ for(EStructuralFeature.Setting nonNavigableInverseReference : collection) {
+ EStructuralFeature structuralFeature = nonNavigableInverseReference.getEStructuralFeature();
+ if(!(nonNavigableInverseReference.getEObject() instanceof View)) {
+ manageFeatureForCross(nonNavigableInverseReference.getEObject(), source, target, structuralFeature);
+ } else if(nonNavigableInverseReference.getEObject() instanceof Diagram) {
+ Diagram di = (Diagram)nonNavigableInverseReference.getEObject();
remove(null, di, null);
}
}
@@ -267,19 +235,19 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
* Checks if a type is compatible to another.
*
* @param type
- * the type
+ * the type
* @param target
- * the target
+ * the target
*
* @return true, if is compatible
*/
public static boolean isCompatible(EClassifier type, EClassifier target) {
Collection<EClassifier> types = new LinkedList<EClassifier>();
- if (target instanceof EClass) {
- EClass eclass = (EClass) target;
+ if(target instanceof EClass) {
+ EClass eclass = (EClass)target;
types.addAll(eclass.getEAllSuperTypes());
}
- if (!types.contains(target)) {
+ if(!types.contains(target)) {
types.add(target);
}
return types.contains(type);
@@ -289,52 +257,44 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
* Manage a feature for the attribute's copy.
*
* @param mixedDomain
- * the mixed domain
+ * the mixed domain
* @param source
- * the source
+ * the source
* @param target
- * the target
+ * the target
* @param feature
- * the e
+ * the e
*/
@SuppressWarnings("unchecked")
- private void manageFeature(EObject source, EObject target,
- EStructuralFeature feature) {
+ private void manageFeature(EObject source, EObject target, EStructuralFeature feature) {
EStructuralFeature targetFeature = getFeature(target, feature.getName());
- if (feature.getUpperBound() <= targetFeature.getUpperBound()
- && feature.getLowerBound() >= targetFeature.getLowerBound()) {
- if (feature.isChangeable() && !feature.isDerived()) {
+ if(feature.getUpperBound() <= targetFeature.getUpperBound() && feature.getLowerBound() >= targetFeature.getLowerBound()) {
+ if(feature.isChangeable() && !feature.isDerived()) {
Object value = source.eGet(feature);
- if (feature.isMany() && targetFeature.isMany()) {
- Collection<EObject> list = (Collection<EObject>) value;
- if (list != null && !list.isEmpty()) {
+ if(feature.isMany() && targetFeature.isMany()) {
+ Collection<EObject> list = (Collection<EObject>)value;
+ if(list != null && !list.isEmpty()) {
Collection<EObject> newList = new LinkedList<EObject>();
newList.addAll(list);
- if (feature instanceof EReference
- && !((EReference) feature).isContainment()) {
- add(new SetValueCommand(new SetRequest(
- editingDomain, target, targetFeature,
- newList)));
- } else if (feature instanceof EReference
- && ((EReference) feature).isContainment()) {
+ if(feature instanceof EReference && !((EReference)feature).isContainment()) {
+ add(new SetValueCommand(new SetRequest(editingDomain, target, targetFeature, newList)));
+ } else if(feature instanceof EReference && ((EReference)feature).isContainment()) {
Collection<Object> toTreat = new LinkedList<Object>();
- for (Object o : newList) {
- if (!alreadyManaged.contains(o)) {
+ for(Object o : newList) {
+ if(!alreadyManaged.contains(o)) {
toTreat.add(o);
alreadyManaged.add(o);
}
}
- add(new CustomAddCommand(editingDomain, target,
- targetFeature, newList, source, feature));
+ add(new CustomAddCommand(editingDomain, target, targetFeature, newList, source, feature));
}
}
- } else if (!feature.isMany() && !targetFeature.isMany()) {
- if (value != null) {
- if (!alreadyManaged.contains(value)) {
+ } else if(!feature.isMany() && !targetFeature.isMany()) {
+ if(value != null) {
+ if(!alreadyManaged.contains(value)) {
alreadyManaged.add(value);
- add(new CustomSetCommand(editingDomain, target,
- targetFeature, value, source, feature));
+ add(new CustomSetCommand(editingDomain, target, targetFeature, value, source, feature));
}
}
}
@@ -347,9 +307,9 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
* Gets a feature from a name
*
* @param eobject
- * the eobject
+ * the eobject
* @param name
- * the name
+ * the name
*
* @return the feature
*/
@@ -378,9 +338,7 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
private Object oldValue = null;
- public CustomSetCommand(TransactionalEditingDomain domain,
- EObject owner, EStructuralFeature feature, Object value,
- EObject old, EStructuralFeature structuralFeature) {
+ public CustomSetCommand(TransactionalEditingDomain domain, EObject owner, EStructuralFeature feature, Object value, EObject old, EStructuralFeature structuralFeature) {
super(new SetRequest(domain, owner, feature, value));
oldObject = old;
oldFeature = structuralFeature;
@@ -388,8 +346,7 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
}
@Override
- protected IStatus doUndo(IProgressMonitor monitor, IAdaptable info)
- throws ExecutionException {
+ protected IStatus doUndo(IProgressMonitor monitor, IAdaptable info) throws ExecutionException {
IStatus result = super.doUndo(monitor, info);
oldObject.eSet(oldFeature, oldValue);
return result;
@@ -409,10 +366,7 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
private EStructuralFeature newFeature;
- public CustomAddCommand(TransactionalEditingDomain editingDomain,
- EObject target, EStructuralFeature targetFeature,
- Collection<EObject> newList, EObject source,
- EStructuralFeature e) {
+ public CustomAddCommand(TransactionalEditingDomain editingDomain, EObject target, EStructuralFeature targetFeature, Collection<EObject> newList, EObject source, EStructuralFeature e) {
super(new SetRequest(editingDomain, target, targetFeature, newList));
oldObject = source;
oldFeature = e;
@@ -421,19 +375,16 @@ public class EObjectInheritanceCopyCommand extends CompositeCommand {
@SuppressWarnings({ "rawtypes", "unchecked" })
@Override
- protected IStatus doUndo(IProgressMonitor monitor, IAdaptable info)
- throws ExecutionException {
+ protected IStatus doUndo(IProgressMonitor monitor, IAdaptable info) throws ExecutionException {
Object values = getElementToEdit().eGet(newFeature);
IStatus result = super.doUndo(monitor, info);
// this test permit to avoid modification from other command
// if getOwner list is empty it will perform error we avoid it
- if (values instanceof Collection<?>
- && !((Collection<?>) values).isEmpty()) {
- Collection<?> collection = (Collection<?>) values;
- Collection<Object> collecOldObject = (Collection) oldObject
- .eGet(oldFeature);
- for (Object o : collection) {
- if (!collecOldObject.contains(o)) {
+ if(values instanceof Collection<?> && !((Collection<?>)values).isEmpty()) {
+ Collection<?> collection = (Collection<?>)values;
+ Collection<Object> collecOldObject = (Collection)oldObject.eGet(oldFeature);
+ for(Object o : collection) {
+ if(!collecOldObject.contains(o)) {
collecOldObject.add(o);
}
}
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/dnd/CommonDropAdapterAssistant.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/dnd/CommonDropAdapterAssistant.java
index b52a4d697eb..c68b875b1b3 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/dnd/CommonDropAdapterAssistant.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/dnd/CommonDropAdapterAssistant.java
@@ -47,16 +47,16 @@ import org.eclipse.jface.util.LocalSelectionTransfer;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.ViewerDropAdapter;
+import org.eclipse.papyrus.commands.CreationCommandDescriptor;
+import org.eclipse.papyrus.commands.CreationCommandRegistry;
+import org.eclipse.papyrus.commands.ICreationCommand;
+import org.eclipse.papyrus.commands.ICreationCommandRegistry;
import org.eclipse.papyrus.commands.wrappers.GMFtoEMFCommandWrapper;
import org.eclipse.papyrus.infra.core.editor.BackboneException;
import org.eclipse.papyrus.infra.core.editor.IMultiDiagramEditor;
-import org.eclipse.papyrus.infra.core.extension.commands.CreationCommandDescriptor;
-import org.eclipse.papyrus.infra.core.extension.commands.CreationCommandRegistry;
-import org.eclipse.papyrus.infra.core.extension.commands.ICreationCommand;
-import org.eclipse.papyrus.infra.core.extension.commands.ICreationCommandRegistry;
import org.eclipse.papyrus.infra.core.resource.ModelSet;
-import org.eclipse.papyrus.infra.core.resource.notation.NotationModel;
import org.eclipse.papyrus.infra.core.utils.EditorUtils;
+import org.eclipse.papyrus.infra.gmfdiag.common.model.NotationModel;
import org.eclipse.papyrus.infra.services.edit.service.ElementEditServiceUtils;
import org.eclipse.papyrus.infra.services.edit.service.IElementEditService;
import org.eclipse.papyrus.views.modelexplorer.Activator;
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/AbstractCommandHandler.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/AbstractCommandHandler.java
index 617f41c8512..9523482ef71 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/AbstractCommandHandler.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/AbstractCommandHandler.java
@@ -25,8 +25,8 @@ import org.eclipse.emf.common.command.Command;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.papyrus.infra.core.services.ServiceException;
-import org.eclipse.papyrus.infra.core.utils.BusinessModelResolver;
import org.eclipse.papyrus.infra.core.utils.ServiceUtilsForActionHandlers;
+import org.eclipse.papyrus.infra.emf.utils.EMFHelper;
import org.eclipse.papyrus.views.modelexplorer.Activator;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PlatformUI;
@@ -85,9 +85,9 @@ public abstract class AbstractCommandHandler extends AbstractModelExplorerHandle
selection = ((IAdaptable)selection).getAdapter(EObject.class);
}
- Object businessObject = BusinessModelResolver.getInstance().getBusinessModel(selection);
- if(businessObject instanceof EObject) {
- eObject = (EObject)businessObject;
+ EObject businessObject = EMFHelper.getEObject(selection);
+ if(businessObject != null) {
+ eObject = businessObject;
}
}
diff --git a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/LoadBrowserCustomization.java b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/LoadBrowserCustomization.java
index 55779b1283c..27aec4e2df8 100644
--- a/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/LoadBrowserCustomization.java
+++ b/plugins/views/modelexplorer/org.eclipse.papyrus.views.modelexplorer/src/org/eclipse/papyrus/views/modelexplorer/handler/LoadBrowserCustomization.java
@@ -37,13 +37,14 @@ import org.eclipse.emf.facet.infra.facet.FacetSet;
import org.eclipse.emf.facet.infra.facet.core.FacetSetCatalog;
import org.eclipse.jface.window.Window;
import org.eclipse.osgi.util.NLS;
+import org.eclipse.papyrus.infra.core.resource.ModelSet;
+import org.eclipse.papyrus.infra.core.resource.ModelUtils;
import org.eclipse.papyrus.infra.core.sasheditor.contentprovider.IPageMngr;
import org.eclipse.papyrus.infra.core.services.ServiceException;
import org.eclipse.papyrus.infra.core.services.ServicesRegistry;
-import org.eclipse.papyrus.infra.core.utils.DiResourceSet;
-import org.eclipse.papyrus.infra.core.utils.EditorUtils;
import org.eclipse.papyrus.infra.core.utils.ServiceUtils;
import org.eclipse.papyrus.infra.core.utils.ServiceUtilsForActionHandlers;
+import org.eclipse.papyrus.uml.tools.model.UmlUtils;
import org.eclipse.papyrus.views.modelexplorer.Activator;
import org.eclipse.papyrus.views.modelexplorer.ModelExplorerPageBookView;
import org.eclipse.swt.widgets.Shell;
@@ -65,7 +66,7 @@ public class LoadBrowserCustomization extends AbstractHandler {
protected CommonNavigator getCommonNavigator() {
IViewPart part = org.eclipse.papyrus.views.modelexplorer.NavigatorUtils.findViewPart(ModelExplorerPageBookView.VIEW_ID);
// the part is only a book, retrieving correct page
- if (part instanceof ModelExplorerPageBookView) {
+ if(part instanceof ModelExplorerPageBookView) {
IViewPart page = ((ModelExplorerPageBookView)part).getActiveView();
if(page instanceof CommonNavigator) {
return ((CommonNavigator)page);
@@ -79,33 +80,28 @@ public class LoadBrowserCustomization extends AbstractHandler {
*/
public Object execute(ExecutionEvent event) throws ExecutionException {
- if (Activator.getDefault().getCustomizationManager() != null) {
- CustomizationManager customizationManager = Activator.getDefault()
- .getCustomizationManager();
- final List<MetamodelView> registeredCustomizations = customizationManager
- .getRegisteredCustomizations();
+ if(Activator.getDefault().getCustomizationManager() != null) {
+ CustomizationManager customizationManager = Activator.getDefault().getCustomizationManager();
+ final List<MetamodelView> registeredCustomizations = customizationManager.getRegisteredCustomizations();
final LoadCustomizationsDialog loadCustomizationsDialog = new LoadCustomizationsDialog(new Shell(), registeredCustomizations, getMetamodels());
- if (Window.OK == loadCustomizationsDialog.open() ) {
+ if(Window.OK == loadCustomizationsDialog.open()) {
try {
customizationManager.clearCustomizations();
- List<MetamodelView> selectedCustomizations = loadCustomizationsDialog
- .getSelectedCustomizations();
+ List<MetamodelView> selectedCustomizations = loadCustomizationsDialog.getSelectedCustomizations();
//before loading, clean all facet to prevent to let not interesting facets.
customizationManager.clearFacets();
- if (loadCustomizationsDialog.isLoadRequiredFacetsSelected()) {
+ if(loadCustomizationsDialog.isLoadRequiredFacetsSelected()) {
// load facets corresponding to customizations
- loadFacetsForCustomizations(selectedCustomizations,
- customizationManager);
+ loadFacetsForCustomizations(selectedCustomizations, customizationManager);
}
- for (MetamodelView metamodelView : selectedCustomizations) {
- customizationManager
- .registerCustomization(metamodelView);
+ for(MetamodelView metamodelView : selectedCustomizations) {
+ customizationManager.registerCustomization(metamodelView);
}
customizationManager.loadCustomizations();
- if (getCommonNavigator() != null) {
+ if(getCommonNavigator() != null) {
Tree tree = getCommonNavigator().getCommonViewer().getTree();
customizationManager.installCustomPainter(tree);
tree.redraw();
@@ -118,7 +114,7 @@ public class LoadBrowserCustomization extends AbstractHandler {
}
// load customizations defined as default through the customization
// extension
- if (getCommonNavigator() != null) {
+ if(getCommonNavigator() != null) {
getCommonNavigator().getCommonViewer().refresh();
}
}
@@ -130,62 +126,51 @@ public class LoadBrowserCustomization extends AbstractHandler {
*
* @return the RessourceSet
*/
- private DiResourceSet getDiResourceSet() {
- return EditorUtils.getDiResourceSet();
+ private ModelSet getModelSet() {
+ return ModelUtils.getModelSet();
}
/**
* load the facets
*
* @param customizations
- * list of customization
+ * list of customization
* @param customizationManager
- * the Customization Manager
+ * the Customization Manager
*/
- protected void loadFacetsForCustomizations(
- final List<MetamodelView> customizations,
- final CustomizationManager customizationManager) {
+ protected void loadFacetsForCustomizations(final List<MetamodelView> customizations, final CustomizationManager customizationManager) {
final Set<Facet> referencedFacets = new HashSet<Facet>();
- final Collection<FacetSet> facetSets = FacetSetCatalog.getSingleton()
- .getAllFacetSets();
+ final Collection<FacetSet> facetSets = FacetSetCatalog.getSingleton().getAllFacetSets();
- for (MetamodelView customization : customizations) {
+ for(MetamodelView customization : customizations) {
String metamodelURI = customization.getMetamodelURI();
// find customized FacetSet
FacetSet customizedFacetSet = null;
- if (metamodelURI != null) {
- for (FacetSet facetSet : facetSets) {
- if (metamodelURI.equals(facetSet.getNsURI())) {
+ if(metamodelURI != null) {
+ for(FacetSet facetSet : facetSets) {
+ if(metamodelURI.equals(facetSet.getNsURI())) {
customizedFacetSet = facetSet;
break;
}
}
}
- if (customizedFacetSet == null) {
+ if(customizedFacetSet == null) {
continue;
}
// find customized Facets
EList<TypeView> types = customization.getTypes();
- for (TypeView typeView : types) {
+ for(TypeView typeView : types) {
String metaclassName = typeView.getMetaclassName();
- Facet facet = findFacetWithFullyQualifiedName(metaclassName,
- customizedFacetSet);
- if (facet != null) {
+ Facet facet = findFacetWithFullyQualifiedName(metaclassName, customizedFacetSet);
+ if(facet != null) {
referencedFacets.add(facet);
} else {
- Activator.log.warn(NLS
- .bind(
- Messages.BrowserActionBarContributor_missingRequiredFacet,
- new Object[] {
- metaclassName,
- customizedFacetSet
- .getName(),
- customization.getName() }));
+ Activator.log.warn(NLS.bind(Messages.BrowserActionBarContributor_missingRequiredFacet, new Object[]{ metaclassName, customizedFacetSet.getName(), customization.getName() }));
}
}
- for (Facet referencedFacet : referencedFacets) {
+ for(Facet referencedFacet : referencedFacets) {
customizationManager.loadFacet(referencedFacet);
}
}
@@ -204,12 +189,11 @@ public class LoadBrowserCustomization extends AbstractHandler {
* @param customizedFacetSet
* @return
*/
- private Facet findFacetWithFullyQualifiedName(final String metaclassName,
- final FacetSet customizedFacetSet) {
+ private Facet findFacetWithFullyQualifiedName(final String metaclassName, final FacetSet customizedFacetSet) {
EList<Facet> facets = customizedFacetSet.getFacets();
- for (Facet facet : facets) {
+ for(Facet facet : facets) {
String facetName = getMetaclassQualifiedName(facet);
- if (metaclassName.equals(facetName)) {
+ if(metaclassName.equals(facetName)) {
return facet;
}
}
@@ -222,12 +206,12 @@ public class LoadBrowserCustomization extends AbstractHandler {
final StringBuilder builder = new StringBuilder();
EPackage ePackage = eClass.getEPackage();
- while (ePackage != null) {
+ while(ePackage != null) {
qualifiedNameParts.add(ePackage.getName());
ePackage = ePackage.getESuperPackage();
}
- for (int i = qualifiedNameParts.size() - 1; i >= 0; i--) {
+ for(int i = qualifiedNameParts.size() - 1; i >= 0; i--) {
builder.append(qualifiedNameParts.get(i) + "."); //$NON-NLS-1$
}
@@ -242,12 +226,11 @@ public class LoadBrowserCustomization extends AbstractHandler {
public String getMetamodelURI() {
try {
- EList<EObject> contents = getDiResourceSet().getModelResource()
- .getContents();
- if (contents.size() > 0) {
+ EList<EObject> contents = UmlUtils.getUmlResource(getModelSet()).getContents();
+ if(contents.size() > 0) {
EObject eObject = contents.get(0);
EClass eClass = eObject.eClass();
- if (eClass != null) {
+ if(eClass != null) {
return eClass.getEPackage().getNsURI();
}
}
@@ -264,14 +247,15 @@ public class LoadBrowserCustomization extends AbstractHandler {
List<EPackage> ePackages = new ArrayList<EPackage>();
ServicesRegistry serviceRegistry = null;
try {
- serviceRegistry = ServiceUtilsForActionHandlers.getInstance()
- .getServiceRegistry();
+ serviceRegistry = ServiceUtilsForActionHandlers.getInstance().getServiceRegistry();
} catch (ServiceException e) {
Activator.log.error(e);
}
- /*we look for the current editors, because their are represented in the model explorer
- using specific facet and uiCustom. (see bug 359692) */
+ /*
+ * we look for the current editors, because their are represented in the model explorer
+ * using specific facet and uiCustom. (see bug 359692)
+ */
IPageMngr pageMngr = null;
try {
pageMngr = ServiceUtils.getInstance().getIPageMngr(serviceRegistry);
@@ -279,23 +263,21 @@ public class LoadBrowserCustomization extends AbstractHandler {
Activator.log.error(e);
}
List<Object> pages = pageMngr.allPages();
- for (int i = 0; i < pages.size(); i++) {
- if (pages.get(i) instanceof EObject) {
- EPackage ePackage = ((EObject) pages.get(i)).eClass()
- .getEPackage();
- if (!ePackages.contains(ePackage)) {
+ for(int i = 0; i < pages.size(); i++) {
+ if(pages.get(i) instanceof EObject) {
+ EPackage ePackage = ((EObject)pages.get(i)).eClass().getEPackage();
+ if(!ePackages.contains(ePackage)) {
ePackages.add(ePackage);
}
}
}
try {
- EList<EObject> contents = getDiResourceSet().getModelResource()
- .getContents();
- if (contents.size() > 0) {
+ EList<EObject> contents = UmlUtils.getUmlResource(getModelSet()).getContents();
+ if(contents.size() > 0) {
EObject eObject = contents.get(0);
EClass eClass = eObject.eClass();
- if (eClass != null) {
+ if(eClass != null) {
ePackages.add(eClass.getEPackage());
}
}
diff --git a/plugins/views/properties/org.eclipse.papyrus.views.properties/META-INF/MANIFEST.MF b/plugins/views/properties/org.eclipse.papyrus.views.properties/META-INF/MANIFEST.MF
index e0a8d0d66ae..fb24c23b658 100644
--- a/plugins/views/properties/org.eclipse.papyrus.views.properties/META-INF/MANIFEST.MF
+++ b/plugins/views/properties/org.eclipse.papyrus.views.properties/META-INF/MANIFEST.MF
@@ -17,17 +17,13 @@ Bundle-ClassPath: .,
Bundle-Name: %pluginName
Bundle-Localization: plugin
Bundle-RequiredExecutionEnvironment: J2SE-1.5
-Require-Bundle: com.ibm.icu,
- org.eclipse.emf;bundle-version="2.6.0",
+Require-Bundle: org.eclipse.emf;bundle-version="2.6.0",
org.eclipse.emf.ecore;bundle-version="2.6.0",
org.eclipse.emf.ecore.xmi;bundle-version="2.5.0",
org.eclipse.emf.databinding;bundle-version="1.2.0",
- org.eclipse.equinox.common;bundle-version="3.6.0",
org.eclipse.ui;bundle-version="3.6.0",
- org.eclipse.osgi;bundle-version="3.6.0",
org.eclipse.core.runtime;bundle-version="3.6.0",
org.eclipse.core.resources;bundle-version="3.6.0",
- org.eclipse.swt,
org.eclipse.jface,
org.eclipse.jface.databinding,
org.eclipse.core.databinding,
@@ -36,18 +32,18 @@ Require-Bundle: com.ibm.icu,
org.eclipse.papyrus.views.properties.model;bundle-version="0.10.0",
org.eclipse.papyrus.infra.services.edit;bundle-version="0.10.0",
org.eclipse.papyrus.infra.widgets;bundle-version="0.10.0",
- org.eclipse.core.databinding.beans;bundle-version="1.2.100",
org.eclipse.emf.facet.infra.query;bundle-version="0.1.0",
org.eclipse.emf.facet.infra.query.core;bundle-version="0.1.0",
org.eclipse.emf.facet.infra.common.core;bundle-version="0.1.0",
org.eclipse.papyrus.views.modelexplorer.widgets;bundle-version="0.10.0",
- org.eclipse.gmf.runtime.diagram.ui;bundle-version="1.5.0",
org.eclipse.papyrus.infra.emf;bundle-version="0.10.0",
org.eclipse.papyrus.infra.tools;bundle-version="0.10.0",
org.eclipse.papyrus.infra.constraints;bundle-version="0.10.0",
org.eclipse.papyrus.infra.core.log;bundle-version="0.10.0",
org.eclipse.emf.facet.infra.browser.uicore;bundle-version="0.2.0",
- org.eclipse.papyrus.infra.core;bundle-version="0.10.0"
+ org.eclipse.papyrus.infra.core;bundle-version="0.10.0",
+ org.eclipse.emf.edit;bundle-version="2.8.0",
+ org.eclipse.ui.views.properties.tabbed;bundle-version="3.5.300"
Bundle-Vendor: %Bundle-Vendor
Bundle-Version: 0.10.0.qualifier
Eclipse-BuddyPolicy: dependent

Back to the top