Wednesday, September 26, 2012

for new object, stableId() not the same before/after persist

Hi there, 

I have an entity proxy object that is created on the client. After persisting into server, I would expect the returned proxy (from server) has the same stableId() (i.e., the two equals)

But this is not happening. I thought GWT documentation says the two should equal to each other. Am I missing something?  Here is the code. 

MyObjectProxy value = request.create(MyObjectProxy.class)            // value.getId() is NULL, stableId() has some value in it

request.persist(value).fire(Receiver(MyObjectProxy response) {          // response.getId() is not null,   stableId() has some value in it
     boolean isSame = response.stableId().equals(value.stableId());     // isSame return false     

Thanks,
yan

--
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/-/BBrtUuiGHW8J.
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