Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 349676 - [Property View][Tab profile] : bug with ProfileApplication
Summary: [Property View][Tab profile] : bug with ProfileApplication
Status: RESOLVED FIXED
Alias: None
Product: Papyrus
Classification: Modeling
Component: Views (show other bugs)
Version: 0.8.0   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 0.8.0   Edit
Assignee: Camille Letavernier CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-17 08:15 EDT by Vincent Lorenzo CLA
Modified: 2013-07-05 12:37 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vincent Lorenzo CLA 2011-06-17 08:15:42 EDT
Steps to reproduce : 
	1/ create a new class diagram
	2/ apply a profile on the model (the root of the diagram)
	3/ create a Package in your diagram
	4/ Select this Package and go in the property view, in the tab Profile
	
Problem 1 : in the field ProfileApplication : a profile appears as applied profile : I think the property view use getAllAppliedProfile instead of getAppliedProfiles, because no profile is applied on the Package

Problem 2 : select this ProfileApplication and click on the red cross to remove it : you get the following exception : 

java.lang.IllegalArgumentException: org.eclipse.uml2.uml.internal.impl.ProfileImpl@16d417c (name: ModelElements, visibility: <unset>)
	at org.eclipse.uml2.uml.internal.operations.PackageOperations.unapplyProfile(PackageOperations.java:665)
	at org.eclipse.uml2.uml.internal.impl.PackageImpl.unapplyProfile(PackageImpl.java:1068)
	at org.eclipse.papyrus.properties.uml.databinding.command.UnapplyProfileCommand.execute(UnapplyProfileCommand.java:45)
	at org.eclipse.emf.common.command.CompoundCommand.execute(CompoundCommand.java:267)
	at org.eclipse.papyrus.properties.uml.databinding.ProfileApplicationObservableList$1.execute(ProfileApplicationObservableList.java:54)
	at org.eclipse.emf.workspace.EMFCommandOperation.doExecute(EMFCommandOperation.java:119)
	at org.eclipse.emf.workspace.AbstractEMFOperation.execute(AbstractEMFOperation.java:150)
	at org.eclipse.core.commands.operations.DefaultOperationHistory.execute(DefaultOperationHistory.java:513)
	at org.eclipse.emf.workspace.impl.WorkspaceCommandStackImpl.doExecute(WorkspaceCommandStackImpl.java:208)
	at org.eclipse.emf.transaction.impl.AbstractTransactionalCommandStack.execute(AbstractTransactionalCommandStack.java:165)
	at org.eclipse.emf.transaction.impl.AbstractTransactionalCommandStack.execute(AbstractTransactionalCommandStack.java:219)
	at org.eclipse.papyrus.properties.uml.databinding.ProfileApplicationObservableList.commit(ProfileApplicationObservableList.java:94)
	at org.eclipse.papyrus.widgets.editors.AbstractEditor.commit(AbstractEditor.java:229)
	at org.eclipse.papyrus.widgets.editors.MultipleValueEditor.commit(MultipleValueEditor.java:384)
	at org.eclipse.papyrus.widgets.editors.MultipleValueEditor.removeAction(MultipleValueEditor.java:398)
	at org.eclipse.papyrus.widgets.editors.MultipleValueEditor.widgetSelected(MultipleValueEditor.java:328)
	at org.eclipse.papyrus.properties.uml.widgets.ProfileApplicationEditor.widgetSelected(ProfileApplicationEditor.java:155)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:240)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4165)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3754)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2696)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660)
	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494)
	at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:123)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Comment 1 Camille Letavernier CLA 2013-07-05 12:37:06 EDT
This bug is fixed in the current version