Wednesday, August 31, 2011

Requestfactory : best practice for persisting updates with Locator

Hi,

I finally did a first try at RF and am wondering what is the best way
to implement the persist method on a Locator class in order to deal
with only the deltas send from the client?

As right now my persist(T objectToPersist) method on the Locator is
doing a create if the object has no id associated to it. This use case
is pretty similar to what i would have done with RPC as the whole
object is being sent evidently. But when i then reload the object from
the server, change some properties on it and call persist again a
pretty 'light' objectToPersist appears in that method which seems to
even have lost the PK on the associations in that object.

So am i missing something or is there a good way to implement those
updates especially when dealing with associations in that object?

Thanks

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to google-web-toolkit+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.

No comments:

Post a Comment