Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 323703 - [Properties view] Unexpected error when editing a Literal Integer
Summary: [Properties view] Unexpected error when editing a Literal Integer
Status: RESOLVED WORKSFORME
Alias: None
Product: Papyrus
Classification: Modeling
Component: Core (show other bugs)
Version: 0.7.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Camille Letavernier CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-26 09:09 EDT by Mathieu Velten CLA
Modified: 2011-09-23 08:01 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 Mathieu Velten CLA 2010-08-26 09:09:19 EDT
I am getting an unexpected error when trying to edit the value of a Literal Integer in the properties view using the UML tab :

Caused by: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
	at org.eclipse.uml2.uml.internal.impl.LiteralIntegerImpl.eSet(LiteralIntegerImpl.java:245)
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjectImpl.java:1081)
	at org.eclipse.papyrus.properties.runtime.modelhandler.emf.StringEMFModelHandler.setValueInModel(StringEMFModelHandler.java:47)
	at org.eclipse.papyrus.properties.runtime.controller.EMFTStructuralFeatureController.setValueInModel(EMFTStructuralFeatureController.java:169)
	at org.eclipse.papyrus.properties.runtime.controller.EMFTPropertyEditorController$EMFTControllerCommand.doExecuteWithResult(EMFTPropertyEditorController.java:94)
	at org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand.doExecute(AbstractTransactionalCommand.java:247)
	at org.eclipse.emf.workspace.AbstractEMFOperation.execute(AbstractEMFOperation.java:150)
	at org.eclipse.core.commands.operations.DefaultOperationHistory.execute(DefaultOperationHistory.java:511)
	... 121 more
	
Using the advanced tab I am getting a very weird behavior : when editing the value (just a click on the "0") the box is filled with something like "org.eclipse.emf.edit.provider.ItemPropertyDescriptor$PropertyValueWrapper@1894f8c".

however if I write a number it just works. This behavior is not trigerred in the properties view of the hierarchical uml editor.
Comment 1 Mathieu Velten CLA 2010-08-30 05:57:06 EDT
The first issue has been fixed by commit 2625.
However the weird behavior in the advanced tab is still present.
Comment 2 Camille Letavernier CLA 2011-09-23 08:01:38 EDT
This problem doesn't seem to exist anymore. I don't know if that's because I cannot reproduce it, if it has been fixed, or if it disappeared with the new property view framework (Which would be strange as the new framework handles the advanced tab exactly as the previous one).