Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Creating a node type that is derived from another yields a runtime crash
Creating a node type that is derived from another yields a runtime crash [message #158065] Thu, 01 November 2007 07:19 Go to next message
Eclipse UserFriend
I have an .ecore model in which one type ("ArtifactContainer") is
derived from another ("Artifact"). Creating and building the GMF
application went fine. But when I try to create a corresponding object
in a diagram I get a runtime-exception (see error msg. and stack dump
below).

I suspect, that the GMF runtime is somehow confused, which objecttype to
create (I could imagine that more than one Policy might apply or
something of that kind...) and hence fails. What do I need to do or add
to support GMF in handling this case?

Michael

------------------------------------------------------------ --------------------
eclipse.buildId=M20070921-1145
java.fullversion=J2RE 1.5.0 IBM J9 2.3 Windows XP x86-32
j9vmwi3223-20070201 (JIT enabled)
J9VM - 20070131_11312_lHdSMR
JIT - 20070109_1805ifx1_r8
GC - 200701_09
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US_CH
Framework arguments: -product org.eclipse.sdk.ide
Command-line arguments: -product org.eclipse.sdk.ide -data C:\Documents
and Settings\mmo\workspace/../runtime-New_configuration -dev
file:C:/Documents and
Settings/mmo/workspace/.metadata/.plugins/org.eclipse.pde.co re/leonardo2/dev.properties
-os win32 -ws win32 -arch x86

Error
Thu Nov 01 12:06:03 CET 2007
execute

org.eclipse.core.commands.ExecutionException: While executing the
operation, an exception occurred
at
org.eclipse.core.commands.operations.DefaultOperationHistory .execute(DefaultOperationHistory.java:519)
at
org.eclipse.gmf.runtime.diagram.ui.parts.DiagramCommandStack .execute(DiagramCommandStack.java:205)
at
org.eclipse.gmf.runtime.diagram.ui.parts.DiagramCommandStack .execute(DiagramCommandStack.java:168)
at
org.eclipse.gmf.runtime.diagram.ui.parts.DiagramCommandStack .execute(DiagramCommandStack.java:155)
at
org.eclipse.gef.tools.AbstractTool.executeCommand(AbstractTo ol.java:388)
at
org.eclipse.gef.tools.AbstractTool.executeCurrentCommand(Abs tractTool.java:400)
at
org.eclipse.gmf.runtime.diagram.ui.tools.CreationTool.perfor mCreation(CreationTool.java:133)
at
org.eclipse.gef.tools.CreationTool.handleButtonUp(CreationTo ol.java:178)
at org.eclipse.gef.tools.AbstractTool.mouseUp(AbstractTool.java :1053)
at org.eclipse.gef.EditDomain.mouseUp(EditDomain.java:259)
at
org.eclipse.gef.ui.parts.DomainEventDispatcher.dispatchMouse Released(DomainEventDispatcher.java:374)
at
org.eclipse.draw2d.LightweightSystem$EventHandler.mouseUp(Li ghtweightSystem.java:538)
at
org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListe ner.java:206)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3682)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3293)
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(NativeMethodAcce ssorImpl.java:64)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:615)
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)
Caused by: org.eclipse.jface.util.Assert$AssertionFailedException: null
argument;failed to create a view
at org.eclipse.jface.util.Assert.isNotNull(Assert.java:153)
at
org.eclipse.gmf.runtime.diagram.ui.commands.CreateCommand.do ExecuteWithResult(CreateCommand.java:99)
at
org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTr ansactionalCommand.doExecute(AbstractTransactionalCommand.ja va:246)
at
org.eclipse.emf.workspace.AbstractEMFOperation.execute(Abstr actEMFOperation.java:137)
at
org.eclipse.gmf.runtime.common.core.command.CompositeCommand .doExecuteWithResult(CompositeCommand.java:406)
at
org.eclipse.gmf.runtime.common.core.command.AbstractCommand. execute(AbstractCommand.java:134)
at
org.eclipse.gmf.runtime.common.core.command.CompositeCommand .doExecuteWithResult(CompositeCommand.java:406)
at
org.eclipse.gmf.runtime.common.core.command.AbstractCommand. execute(AbstractCommand.java:134)
at
org.eclipse.gmf.runtime.common.core.command.CompositeCommand .doExecuteWithResult(CompositeCommand.java:406)
at
org.eclipse.gmf.runtime.common.core.command.AbstractCommand. execute(AbstractCommand.java:134)
at
org.eclipse.core.commands.operations.DefaultOperationHistory .execute(DefaultOperationHistory.java:511)
.... 37 more
------------------------------------------------------------ --------------------
Re: Creating a node type that is derived from another yields a runtime crash [message #158099 is a reply to message #158065] Thu, 01 November 2007 09:37 Go to previous message
Eclipse UserFriend
Hi Michael,

This issue has been discussed several times here. The most likely cause
is that you have a feature initializer for the derived element, but do
not declare a domain specialization constraint (or declare one that does
not match the initializer).
See https://bugs.eclipse.org/bugs/show_bug.cgi?id=195272 for possible
fixes and/or workarounds.

Best regards,
Boris

Michael Moser wrote:
> I have an .ecore model in which one type ("ArtifactContainer") is
> derived from another ("Artifact"). Creating and building the GMF
> application went fine. But when I try to create a corresponding object
> in a diagram I get a runtime-exception (see error msg. and stack dump
> below).
>
> I suspect, that the GMF runtime is somehow confused, which objecttype to
> create (I could imagine that more than one Policy might apply or
> something of that kind...) and hence fails. What do I need to do or add
> to support GMF in handling this case?
>
> Michael
>
> ------------------------------------------------------------ --------------------
>
> eclipse.buildId=M20070921-1145
> java.fullversion=J2RE 1.5.0 IBM J9 2.3 Windows XP x86-32
> j9vmwi3223-20070201 (JIT enabled)
> J9VM - 20070131_11312_lHdSMR
> JIT - 20070109_1805ifx1_r8
> GC - 200701_09
> BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US_CH
> Framework arguments: -product org.eclipse.sdk.ide
> Command-line arguments: -product org.eclipse.sdk.ide -data C:\Documents
> and Settings\mmo\workspace/../runtime-New_configuration -dev
> file:C:/Documents and
> Settings/mmo/workspace/.metadata/.plugins/org.eclipse.pde.co re/leonardo2/dev.properties
> -os win32 -ws win32 -arch x86
>
> Error
> Thu Nov 01 12:06:03 CET 2007
> execute
>
> org.eclipse.core.commands.ExecutionException: While executing the
> operation, an exception occurred
> at
> org.eclipse.core.commands.operations.DefaultOperationHistory .execute(DefaultOperationHistory.java:519)
>
> at
> org.eclipse.gmf.runtime.diagram.ui.parts.DiagramCommandStack .execute(DiagramCommandStack.java:205)
>
> at
> org.eclipse.gmf.runtime.diagram.ui.parts.DiagramCommandStack .execute(DiagramCommandStack.java:168)
>
> at
> org.eclipse.gmf.runtime.diagram.ui.parts.DiagramCommandStack .execute(DiagramCommandStack.java:155)
>
> at org.eclipse.gef.tools.AbstractTool.executeCommand(AbstractTo ol.java:388)
> at
> org.eclipse.gef.tools.AbstractTool.executeCurrentCommand(Abs tractTool.java:400)
>
> at
> org.eclipse.gmf.runtime.diagram.ui.tools.CreationTool.perfor mCreation(CreationTool.java:133)
>
> at org.eclipse.gef.tools.CreationTool.handleButtonUp(CreationTo ol.java:178)
> at org.eclipse.gef.tools.AbstractTool.mouseUp(AbstractTool.java :1053)
> at org.eclipse.gef.EditDomain.mouseUp(EditDomain.java:259)
> at
> org.eclipse.gef.ui.parts.DomainEventDispatcher.dispatchMouse Released(DomainEventDispatcher.java:374)
>
> at
> org.eclipse.draw2d.LightweightSystem$EventHandler.mouseUp(Li ghtweightSystem.java:538)
>
> at
> org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListe ner.java:206)
> at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66)
> at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
> at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3682)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3293)
> 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(NativeMethodAcce ssorImpl.java:64)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:43)
>
> at java.lang.reflect.Method.invoke(Method.java:615)
> 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)
> Caused by: org.eclipse.jface.util.Assert$AssertionFailedException: null
> argument;failed to create a view
> at org.eclipse.jface.util.Assert.isNotNull(Assert.java:153)
> at
> org.eclipse.gmf.runtime.diagram.ui.commands.CreateCommand.do ExecuteWithResult(CreateCommand.java:99)
>
> at
> org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTr ansactionalCommand.doExecute(AbstractTransactionalCommand.ja va:246)
>
> at
> org.eclipse.emf.workspace.AbstractEMFOperation.execute(Abstr actEMFOperation.java:137)
>
> at
> org.eclipse.gmf.runtime.common.core.command.CompositeCommand .doExecuteWithResult(CompositeCommand.java:406)
>
> at
> org.eclipse.gmf.runtime.common.core.command.AbstractCommand. execute(AbstractCommand.java:134)
>
> at
> org.eclipse.gmf.runtime.common.core.command.CompositeCommand .doExecuteWithResult(CompositeCommand.java:406)
>
> at
> org.eclipse.gmf.runtime.common.core.command.AbstractCommand. execute(AbstractCommand.java:134)
>
> at
> org.eclipse.gmf.runtime.common.core.command.CompositeCommand .doExecuteWithResult(CompositeCommand.java:406)
>
> at
> org.eclipse.gmf.runtime.common.core.command.AbstractCommand. execute(AbstractCommand.java:134)
>
> at
> org.eclipse.core.commands.operations.DefaultOperationHistory .execute(DefaultOperationHistory.java:511)
>
> .... 37 more
> ------------------------------------------------------------ --------------------
>
Previous Topic:Are connection labels' fonts chosen at random?
Next Topic:GMF diagram and UI Form in the same MultiPageEditor
Goto Forum:
  


Current Time: Thu May 29 03:42:30 EDT 2025

Powered by FUDForum. Page generated in 0.02687 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top