Serialization errors
[email protected] Thu, 22 Jan 2009 07:32:00 -0800 (PST)
| Newsgroups | gmane.comp.java.orm.simpleorm |
|---|---|
| Message-ID | <23405065.21232638320524.JavaMail.SYSTEM@blacktip> |
Hello, I'm getting errors trying to deserialize some SimpleORM objects. (using serialization is necessary due to the the way I am integrating SimpleORM with Wicket) It seems that SRecordMeta uses readResolve() to treat itself as a singleton, but I don't think that you can do this if the object graph that you're serializing contains the record meta (such as if you're serializing a SFieldMeta), because of the wording here: http://java.sun.com/j2se/1.3/docs/guide/serialization/spec/input.doc6.html (the "Note" section in particular). The error I'm getting is: java.lang.NullPointerException at simpleorm.dataset.SRecordMeta.getField(SRecordMeta.java:246) at simpleorm.dataset.SFieldMeta.readResolve(SFieldMeta.java:186) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at java.io.ObjectStreamClass.invokeReadResolve(ObjectStreamClass.java:1033) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1728) ...etc Any help is appreciated, Thanks, Carl Gould Inductive Automation [email protected] 1.800.266.7798 __._,_.___ Your email settings: Individual Email|Traditional Change settings via the Web (Yahoo! ID required) Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe __,_._,___