On Wednesday, July 18, 2012 4:45:05 PM UTC+2, Yan wrote:
>
> Hi there,
>
> I have a parent class and child class. Child class has a lot of data. The 
> parent contains a list of child objects.  Child is never loaded/updated by 
> themselves, they are always maintained when user reads/updates on a parent.
>
> The question, Parent makes a natural fit for EntityProxy. Because I want 
> to take advantage of GWT client only send delta to server, I think Child 
> should be another EntityProxy (not ValueProxy). Is that correct?
>
> Is this a good determination when to use ValueProxy vs. EntityProxy: 
> whether GWT client sends only delta or the whole serialized object to 
> server?
>

The main difference between EntityProxy and ValueProxy is that EntityProxy 
have an "identity": there's an ID that can be used to map to a given 
"entity" on the server. This is what enables the use of deltas (because you 
can retrieve the entity the diff should be applied to) but that's a bonus 
feature, not a "discriminator".
In other words: to be able to benefit from "deltas", your data must first 
be "identifiable". If that's the case, then you have the choice of 
EntityProxy vs. ValueProxy (and I'd rather go for EntityProxy). Otherwise, 
you have no choice but using ValueProxy.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/Wog4_JbPxCwJ.
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-web-toolkit?hl=en.

Reply via email to