Issue Details (XML | Word | Printable)

Key: NUCXML-39
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Erik Bengtson
Reporter: Erik Bengtson
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
DataNucleus Store XML

Persisting types will enum typed fields causes nullpointerexception

Created: 06/Feb/10 11:01 AM   Updated: 21/Apr/10 07:42 PM   Resolved: 06/Feb/10 12:29 PM
Component/s: Persistence
Affects Version/s: 1.0.8, 2.0.0.release, 2.0.1
Fix Version/s: 2.0.2

Forum Thread URL: http://www.jpox.org/servlet/forum/viewthread_thread,5960


 Description  « Hide
I have a problem using Enum, I think there is something I misunderstand.
I have an enum E and in a class C I have declared a variable V whose type is E.
In the xml file, I have only <field name="V" />, nothing more.
And then, when I try to store it using the XML datastore, I have the following error :
Caused by: java.lang.NullPointerException
at org.datanucleus.store.xml.binder.XmlRootElementHandler.invoke(XmlRootElementHandler.java:63)
at $Proxy11.name(Unknown Source)
at com.sun.xml.bind.v2.model.impl.TypeInfoImpl.parseElementName(TypeInfoImpl.java:78)
at com.sun.xml.bind.v2.model.impl.EnumLeafInfoImpl.<init>(EnumLeafInfoImpl.java:64)
at com.sun.xml.bind.v2.model.impl.RuntimeEnumLeafInfoImpl.<init>(RuntimeEnumLeafInfoImpl.java:46)

Sort Order: Ascending order - Click to sort in descending order
There are no comments yet on this issue.