| Summary: | [Activity diagram] Cannot create guards | ||
|---|---|---|---|
| Product: | [Modeling] Papyrus | Reporter: | Emmanuel.Leguy |
| Component: | Diagram | Assignee: | Anatoliy Tischenko <tischenko> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | major | ||
| Priority: | P3 | CC: | borlander, papyrus-bugs, shatilov |
| Version: | unspecified | ||
| Target Milestone: | 1.1.0 | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Whiteboard: | |||
|
Description
Emmanuel.Leguy
Setting a guard of an edge generates an NPE. Steps to reproduce this behavior are : 1. Create an edge (control/object flow) between a decision node and another action node 2. Select the edge that you just created 3. Go through the property view and click on the plus button next to the "Guard" property 4. Choose "Expression" on the generated list 5. Specify the type of this expression as being Boolean 6. Create a new operand being an OpaqueAction 7. Select the Java language 8. Fill out the body of the expression with a Java expression 9. Click Ok for both opened popup 10. The trace produced by the program is the following one java.lang.NullPointerException at java.lang.StringBuffer.<init>(Unknown Source) at org.eclipse.papyrus.uml.tools.utils.ValueSpecificationUtil.getSpecificationValue(ValueSpecificationUtil.java:83) at org.eclipse.papyrus.uml.diagram.activity.parser.custom.EdgeGuardParser.getValueString(EdgeGuardParser.java:136) at org.eclipse.papyrus.uml.diagram.activity.parser.custom.EdgeGuardParser.getPrintString(EdgeGuardParser.java:118) at org.eclipse.papyrus.uml.diagram.activity.edit.parts.ControlFlowGuardEditPart.getLabelText(ControlFlowGuardEditPart.java:246) at org.eclipse.papyrus.uml.diagram.activity.edit.parts.ControlFlowGuardEditPart.refreshLabel(ControlFlowGuardEditPart.java:475) at org.eclipse.papyrus.uml.diagram.activity.edit.parts.ControlFlowGuardEditPart.handleNotificationEvent(ControlFlowGuardEditPart.java:698) at org.eclipse.gmf.runtime.diagram.ui.editparts.GraphicalEditPart.notifyChanged(GraphicalEditPart.java:1438) at org.eclipse.gmf.runtime.diagram.core.listener.DiagramEventBroker.fireNotification(DiagramEventBroker.java:504) at org.eclipse.gmf.runtime.diagram.core.listener.DiagramEventBroker.resourceSetChanged(DiagramEventBroker.java:399) at org.eclipse.gmf.runtime.diagram.ui.DiagramEventBrokerThreadSafe.resourceSetChanged(DiagramEventBrokerThreadSafe.java:73) at org.eclipse.emf.transaction.impl.TransactionalEditingDomainImpl$1.run(TransactionalEditingDomainImpl.java:781) at org.eclipse.emf.transaction.impl.TransactionalEditingDomainImpl.runExclusive(TransactionalEditingDomainImpl.java:328) at org.eclipse.emf.transaction.impl.TransactionalEditingDomainImpl.postcommit(TransactionalEditingDomainImpl.java:771) at org.eclipse.emf.transaction.impl.TransactionalEditingDomainImpl.deactivate(TransactionalEditingDomainImpl.java:543) at org.eclipse.emf.transaction.impl.TransactionImpl.close(TransactionImpl.java:712) at org.eclipse.emf.transaction.impl.TransactionImpl.commit(TransactionImpl.java:474) at org.eclipse.emf.workspace.AbstractEMFOperation.execute(AbstractEMFOperation.java:155) at org.eclipse.core.commands.operations.DefaultOperationHistory.execute(DefaultOperationHistory.java:513) at org.eclipse.papyrus.commands.CheckedOperationHistory.execute(CheckedOperationHistory.java:182) at org.eclipse.papyrus.commands.NotifyingWorkspaceCommandStack.doExecute(NotifyingWorkspaceCommandStack.java:252) 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.uml.tools.databinding.PapyrusObservableValue.doSetValue(PapyrusObservableValue.java:77) at org.eclipse.core.databinding.observable.value.AbstractObservableValue.setValue(AbstractObservableValue.java:55) at org.eclipse.papyrus.infra.widgets.editors.ReferenceDialog.setValue(ReferenceDialog.java:421) at org.eclipse.papyrus.infra.widgets.editors.ReferenceDialog.createAction(ReferenceDialog.java:212) at org.eclipse.papyrus.infra.widgets.editors.ReferenceDialog.widgetSelected(ReferenceDialog.java:370) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:248) 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:4169) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3758) at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1057) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:941) at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:79) at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:588) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:543) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124) 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:354) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:181) 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) Gerrit contribution: https://git.eclipse.org/r/#/c/34020/ Merged to master 1.0-maintenance gerrit contribution: https://git.eclipse.org/r/#/c/40257/ (merged) |