Hello Yoann,
Please check out the section titled "Dependent Children and Cascading
Deletes" at
http://code.google.com/appengine/docs/java/datastore/relationships.html
Add the annotation
@Persistent(dependent = "true")
to make the tie the POJOLocation life cycle to the parent.
On Mon, Jan 3, 2011 at 3:52 AM, yoyo <[email protected]> wrote:
> I answer to myself.
>
> Before to do the setXXX(), I must delete the previous object.
>
> Like this :
>
> POJOUser user = pm.getObjectById(POJOUser.class, username);
> pm.deletePersistent(user.getLastLocation());
> user.setLastLocation(new POJOLocation(newLocation));
>
> And now, it works. Moreover, old references are deleted of the store.
>
> I hope this tips will help someone.
>
> Yoann
>
> --
> 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
> [email protected].
> To unsubscribe from this group, send email to
> [email protected]<google-appengine-java%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-appengine-java?hl=en.
>
--
-- A. Stevko
===========
"If everything seems under control, you're just not going fast enough." M.
Andretti
--
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 [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-appengine-java?hl=en.