I'm using PagingScrollTable from GWT Incubator. And I've wrote small
service for data retrieving:
public SerializableResponse<ProjectInfo> loadAllProjects(Request
request) {
List<Project> list = projectDao.loadAll();
return new SerializableResponse<ProjectInfo>(
convert(list),
convertRowsData(list)
);
}
SerializableResponse class defined as:
public static class SerializableResponse<R extends Serializable>
extends
Response<R> implements IsSerializable {
private Collection<Collection<Serializable>> rows;
///////// SKIPPED
}
Response class also contains one field:
public abstract static class Response<R> {
private List<R> rowValues;
}
The problem is that on my client side I don't see row values which was
converted by convertRowsData(list) method. I've taken a look at GWT
RPC implementation and found the place where problem is.
com.google.gwt.user.server.rpc.impl.SerializabilityUtil, public static
Field[] applyFieldSerializationPolicy(Class<?> clazz) method.
invocation of
Field[] fields = clazz.getDeclaredFields();
returns only 'rows' field from SerializableResponse class. And skips
'rowValues' field from Response class.
This is the reason why rowValues data lost in serialization process.
So, how I can avoid this problem? Does it has sense to post the bug?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" 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-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---