DiagramEditDomain cannot be cast to BpmnDiagramEditingDomain [message #608494] |
Wed, 09 January 2008 21:33 |
Eclipse User |
|
|
|
Hi!
I posted this already in the eclipse.moeling.fm newsgroup and was redirected
here:
I'm working on a tool integrating a GMF based editor and a TextEditor (code
is genereated from the Graph and shown in the TextEditor) in a
MultiPageEditor.
The integration is done, everything is working but often I receive the error
(when selecting an object within the graph or when deleting an object):
java.lang.ClassCastException:
org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditDomain cannot be cast to
org.eclipse.stp.bpmn.diagram.part.BpmnDiagramEditDomain
at
org.eclipse.stp.bpmn.diagram.actions.GroupAction.getSelectio n(GroupAction.java:504)
at
org.eclipse.gmf.runtime.common.ui.action.AbstractActionHandl er.getStructuredSelection(AbstractActionHandler.java:434)
at
org.eclipse.stp.bpmn.diagram.actions.GroupAction.refresh(Gro upAction.java:194)
at
org.eclipse.gmf.runtime.common.ui.action.AbstractActionHandl er.selectionChanged(AbstractActionHandler.java:387)
at
org.eclipse.ui.part.MultiPageSelectionProvider$1.run(MultiPa geSelectionProvider.java:109)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
at
org.eclipse.ui.part.MultiPageSelectionProvider.fireEventChan ge(MultiPageSelectionProvider.java:107)
at
org.eclipse.ui.part.MultiPageSelectionProvider.fireSelection Changed(MultiPageSelectionProvider.java:89)
at
org.eclipse.ui.part.MultiPageEditorSite.handleSelectionChang ed(MultiPageEditorSite.java:452)
at
org.eclipse.ui.part.MultiPageEditorSite$2.selectionChanged(M ultiPageEditorSite.java:368)
at
org.eclipse.gmf.runtime.diagram.ui.parts.DiagramGraphicalVie wer.flushSelectionEvents(DiagramGraphicalViewer.java:269)
at
org.eclipse.gmf.runtime.diagram.ui.parts.DiagramGraphicalVie wer$1.run(DiagramGraphicalViewer.java:247)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:3 5)
at
org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchr onizer.java:123)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.jav a:3659)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3296)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:2389)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:22 19)
at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
at
org.eclipse.core.databinding.observable.Realm.runWithDefault (Realm.java:289)
at
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:461)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
at
org.eclipse.ui.internal.ide.application.IDEApplication.start (IDEApplication.java:106)
at
org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:169)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:106)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:76)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:363)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:176)
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: 508)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:447)
at org.eclipse.equinox.launcher.Main.run(Main.java:1173)
at org.eclipse.equinox.launcher.Main.main(Main.java:1148)
The error doesn't affect my editor, everything is working and I have
absolutely no idea where this comes from or how I could fix this...
especially cause there are no classes I created in the error message. Any
ideas? I could really need some help here!
Kind regards,
Markus
|
|
|
Re: DiagramEditDomain cannot be cast to BpmnDiagramEditingDomain [message #608495 is a reply to message #608494] |
Wed, 09 January 2008 22:42 |
Eclipse User |
|
|
|
Originally posted by: atoulme.intalio.com
Hi Markus,
in your editor you need to make sure the DiagramEditDomain you use is
BpmnDiagramEditDomain.
In our editor for example we override this method from DiagramEditor:
/**
* Creates a diagram edit domain cutomized with the default
selection tool.
*/
@Override
protected void createDiagramEditDomain() {
DiagramEditDomain editDomain = new BpmnDiagramEditDomain(this);
editDomain.setActionManager(createActionManager());
setEditDomain(editDomain);
}
I hope this helps.
Antoine
Markus Gieser wrote:
> Hi!
>
> I posted this already in the eclipse.moeling.fm newsgroup and was redirected
> here:
>
> I'm working on a tool integrating a GMF based editor and a TextEditor (code
> is genereated from the Graph and shown in the TextEditor) in a
> MultiPageEditor.
>
> The integration is done, everything is working but often I receive the error
> (when selecting an object within the graph or when deleting an object):
>
> java.lang.ClassCastException:
> org.eclipse.gmf.runtime.diagram.ui.parts.DiagramEditDomain cannot be cast to
> org.eclipse.stp.bpmn.diagram.part.BpmnDiagramEditDomain
> at
> org.eclipse.stp.bpmn.diagram.actions.GroupAction.getSelectio n(GroupAction.java:504)
> at
> org.eclipse.gmf.runtime.common.ui.action.AbstractActionHandl er.getStructuredSelection(AbstractActionHandler.java:434)
> at
> org.eclipse.stp.bpmn.diagram.actions.GroupAction.refresh(Gro upAction.java:194)
> at
> org.eclipse.gmf.runtime.common.ui.action.AbstractActionHandl er.selectionChanged(AbstractActionHandler.java:387)
> at
> org.eclipse.ui.part.MultiPageSelectionProvider$1.run(MultiPa geSelectionProvider.java:109)
> at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
> at
> org.eclipse.ui.part.MultiPageSelectionProvider.fireEventChan ge(MultiPageSelectionProvider.java:107)
> at
> org.eclipse.ui.part.MultiPageSelectionProvider.fireSelection Changed(MultiPageSelectionProvider.java:89)
> at
> org.eclipse.ui.part.MultiPageEditorSite.handleSelectionChang ed(MultiPageEditorSite.java:452)
> at
> org.eclipse.ui.part.MultiPageEditorSite$2.selectionChanged(M ultiPageEditorSite.java:368)
> at
> org.eclipse.gmf.runtime.diagram.ui.parts.DiagramGraphicalVie wer.flushSelectionEvents(DiagramGraphicalViewer.java:269)
> at
> org.eclipse.gmf.runtime.diagram.ui.parts.DiagramGraphicalVie wer$1.run(DiagramGraphicalViewer.java:247)
> at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:3 5)
> at
> org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchr onizer.java:123)
> at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.jav a:3659)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3296)
> at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:2389)
> at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353)
> at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:22 19)
> at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
> at
> org.eclipse.core.databinding.observable.Realm.runWithDefault (Realm.java:289)
> at
> org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:461)
> at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
> at
> org.eclipse.ui.internal.ide.application.IDEApplication.start (IDEApplication.java:106)
> at
> org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:169)
> at
> org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:106)
> at
> org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:76)
> at
> org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:363)
> at
> org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:176)
> 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: 508)
> at org.eclipse.equinox.launcher.Main.basicRun(Main.java:447)
> at org.eclipse.equinox.launcher.Main.run(Main.java:1173)
> at org.eclipse.equinox.launcher.Main.main(Main.java:1148)
>
> The error doesn't affect my editor, everything is working and I have
> absolutely no idea where this comes from or how I could fix this...
> especially cause there are no classes I created in the error message. Any
> ideas? I could really need some help here!
>
> Kind regards,
> Markus
>
>
--
Intalio, the Open Source BPMS Company
<a href="http://www.intalio.com">http://www.intalio.com</a>
<a href="http://bpms.intalio.com">Community website</a>
|
|
|
Powered by
FUDForum. Page generated in 0.02902 seconds