EMF Forms Rules NullpointerException [message #1386966] |
Mon, 23 June 2014 10:09 |
Christian Reuter Messages: 34 Registered: October 2010 |
Member |
|
|
Hi,
I want to create a view model with EMF Forms as described in the EMF Forms tutorial (http://eclipsesource.com/blogs/tutorials/getting-started-with-emf-forms-1-2-x/).
I am trying to define a simple rule which hides a control based on the setting of another (boolean) control.
I first add a "Show Rule" element to the control to be hidden, than I add a "Leaf Condition" element to the "Show Rule" element.
When I press the button "Select Object" of the "leaf Condition" element I get the following error log:
!ENTRY org.eclipse.ui 4 0 2014-06-23 11:57:54.982
!MESSAGE Unhandled event loop exception
!STACK 0
java.lang.NullPointerException
at org.eclipse.emf.ecp.view.editor.controls.ExpectedValueControl$1.widgetSelected(ExpectedValueControl.java:92)
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:1057)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4170)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3759)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1113)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:997)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:140)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:611)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:567)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
at org.eclipse.emf.ecp.application3x.Application.start(Application.java:30)
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)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
at org.eclipse.equinox.launcher.Main.main(Main.java:1426)
I checked out and debugged the sources. The problem is that the field "domainModelReference" of the class "LeafCondition" is never set.
However the button listener directly accesses it without checking for null.
I did set the domain model reference for all controls in the view model so the field should have been set!
I am using eclipse kepler and ECP 1.2.1.
Any help is highly appreciated.
Thx,
chris
[Updated on: Mon, 23 June 2014 10:19] Report message to a moderator
|
|
|
|
Re: EMF Forms Rules NullpointerException [message #1387015 is a reply to message #1386966] |
Mon, 23 June 2014 13:48 |
Maximilian Koegel Messages: 253 Registered: July 2009 |
Senior Member |
|
|
Hi Chris,
thank you for reporting this, it is a bug, could you please open a
bugzilla, thanks!
Cheers,
Maximilian
Am 23.06.2014 12:09, schrieb Christian Reuter:
> Hi,
>
> I want to create a view model with EMF Forms as described in the EMF
> Forms tutorial
> (http://eclipsesource.com/blogs/tutorials/getting-started-with-emf-forms-1-2-x/).
>
>
> I am trying to define a simple rule which hides a control based on the
> setting of another (boolean) control.
> I first add a "Show Rule" to the control to be hidden, than I add a
> "Leaf Condition" to the "Show Rule" element.
> When I press the button "Select Object" I get the following error log:
>
>
> !ENTRY org.eclipse.ui 4 0 2014-06-23 11:57:54.982
> !MESSAGE Unhandled event loop exception
> !STACK 0
> java.lang.NullPointerException
> at
> org.eclipse.emf.ecp.view.editor.controls.ExpectedValueControl$1.widgetSelected(ExpectedValueControl.java:92)
>
> 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:1057)
> at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4170)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3759)
> at
> org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1113)
>
> at
> org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
>
> at
> org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:997)
>
> at
> org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:140)
>
> at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:611)
> at
> org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
>
> at
> org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:567)
> at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
> at
> org.eclipse.emf.ecp.application3x.Application.start(Application.java:30)
> 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)
> at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
> at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
> at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
> at org.eclipse.equinox.launcher.Main.main(Main.java:1426)
>
>
> I checked out and debugged the sources. The problem is that the field
> "domainModelReference" of the class "LeafCondition" is never set.
> However the button listener directly accesses it without checking for null.
>
> I did set the domain model reference for all controls in the view model
> so the field should have been set!
>
> I am using eclipse kepler and ECP 1.2.1.
>
> Any help is highly appreciated.
>
> Thx,
>
> chris
>
--
Maximilian Kögel
Get Professional Eclipse Support: http://eclipsesource.com/munich
|
|
|
|
Powered by
FUDForum. Page generated in 0.02023 seconds