[appengine-java] Re: Inheritance in JDO

2009-09-03 Thread bgood

Does anyone know if this was fixed in the 1.2.5 SDK release announced
today ?  (based on the status of the datanucleus-appengine/issues/list
I would guess no.)

I'd really like to start using JDO inheritance when it comes
available.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en
-~--~~~~--~~--~--~---



[appengine-java] Re: Inheritance in JDO

2009-08-24 Thread Tom Ball
Does anyone know if JPA supports polymorphism?  I've been working with JDO
because it appears to be better documented right now, but I'd switch for a
more Java-like model.
Tom

On Sun, Aug 23, 2009 at 7:22 AM, David Given d...@cowlark.com wrote:


 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 jd wrote:
 [...]
  I have a structure similar to this this:
 [...]
  class Zoo
  class Zebra implements Animal
  class Donkey implements Animal
 [...]
  javax.jdo.JDOUserException: Field animal is declared as a reference
  type (interface/Object) but no implementation classes of Animal have
  been found!

 JDO on App Engine doesn't support polymorphism, as I understand it,
 which means you have to store your Zebras and Donkeys separately. I take
 it that what you want is a mixed bag of Animals of differing objects?

 The only way I found of doing that was to manually serialise my objects
 and store them in Blobs. It's not as hard as it looks, as the low-level
 API is quite nicely designed, but you do need to explicitly pull fields
 you want indexed out of the object before serialisation and store them
 as indexable properties on the entity.

 - --
 ┌─── dg@cowlark.com ─ http://www.cowlark.com ─
 │
 │ People who think they know everything really annoy those of us who
 │ know we don't. --- Bjarne Stroustrup
 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.4.9 (GNU/Linux)
 Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

 iD8DBQFKkVCdf9E0noFvlzgRAmmBAJwIHs8T5Qy5t0FgQ/ik4oTdOca1rACg0Oy1
 IzwfB2MUttjgJZMdgAetr38=
 =U8uT
 -END PGP SIGNATURE-

 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google App Engine for Java group.
To post to this group, send email to google-appengine-java@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en
-~--~~~~--~~--~--~---