On Wednesday, January 2, 2013 6:39:47 PM UTC+1, Thomas Broyer wrote:
>
>
>
> On Wednesday, January 2, 2013 6:16:36 PM UTC+1, Brandon Donnelson wrote:
>>
>> Good point, but I don't think that's it. I walked the code several 
>> finding the loop on it self here: 
>> http://code.google.com/searchframe#T04cSGC7sWI/trunk/user/src/com/google/gwt/user/server/rpc/impl/SerializabilityUtil.java&q=SerializabilityUtil%20package:google-web-toolkit%5C.googlecode%5C.com&l=870
>
>
> That indeed looks strange (I haven't looked closely at the code though).
>

I looked a bit more at it and there's actually nothing that strange here. 
One could say the code could be better optimized but that's it.
This method is used to generate a "signature" for a type that will change 
whenever its serialization changes. When a type has no 
CustomFieldSerializer, its fields are used; otherwise, because we cannot 
tell which fields will be serialized, the signature for the type is the 
signature for its CustomFieldSerializer. That's the reason for the 
recursive call. It's not expected then that the CustomFieldSerializer 
itself has a CustomFieldSerializer. If you want to make it better, then add 
a boolean argument to the method to tell whether a CustomFieldSerializer 
should be used or not (or maybe split the method in two), so that when 
computing the signature for the CustomFieldSerializer we don't look for the 
CustomFieldSerializer's CustomFieldSerializer.

-- 
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/-/5PvdRqtiRvkJ.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to