Can't get Criteria to work
Hi all,
First off: thanks so much for this discussion, it helped me a great lot with getting GWT-RPC datasources working.
The only problem I still have left is fetching data using Criteria. I've looked at and tried the example from this thread with the GWTCriterion class, but I'm getting this error when I'm running it:
I read somewhere that since GWT 2.0 (which I'm using), the IsSerializable is re-introduced instead of the regular Serializable, which might make this old example to crash?
Does anyone have this working (GWT-RPC fetching with Criteria) in GWT 2.0?
Thanks for any help!
Regards,
Kees.
Hi all,
First off: thanks so much for this discussion, it helped me a great lot with getting GWT-RPC datasources working.
The only problem I still have left is fetching data using Criteria. I've looked at and tried the example from this thread with the GWTCriterion class, but I'm getting this error when I'm running it:
Code:
[ERROR] com.google.gwt.user.client.rpc.SerializationException [ERROR] at com.google.gwt.user.client.rpc.impl.SerializerBase.check(SerializerBase.java:161) [ERROR] at com.google.gwt.user.client.rpc.impl.SerializerBase.serialize(SerializerBase.java:145) [ERROR] at com.google.gwt.user.client.rpc.impl.ClientSerializationStreamWriter.serialize(ClientSerializationStreamWriter.java:199) [ERROR] at com.google.gwt.user.client.rpc.impl.AbstractSerializationStreamWriter.writeObject(AbstractSerializationStreamWriter.java:129) [ERROR] at nl.kees.test.db.client.util.criteria.GWTCriterion_FieldSerializer.serialize(GWTCriterion_FieldSerializer.java:32) [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [ERROR] at java.lang.reflect.Method.invoke(Method.java:592) [ERROR] at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103) [ERROR] at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71) [ERROR] at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:157) [ERROR] at com.google.gwt.dev.shell.BrowserChannel.reactToMessagesWhileWaitingForReturn(BrowserChannel.java:1713) [ERROR] at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:165) [ERROR] at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:120) [ERROR] at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:507) [ERROR] at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:284) [ERROR] at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107) [ERROR] at com.google.gwt.user.client.rpc.impl.SerializerBase$MethodMap$.serialize$(SerializerBase.java) [ERROR] at com.google.gwt.user.client.rpc.impl.SerializerBase.serialize(SerializerBase.java:147) [ERROR] at com.google.gwt.user.client.rpc.impl.ClientSerializationStreamWriter.serialize(ClientSerializationStreamWriter.java:199) [ERROR] at com.google.gwt.user.client.rpc.impl.AbstractSerializationStreamWriter.writeObject(AbstractSerializationStreamWriter.java:129) [ERROR] at nl.kees.test.db.client.admin.AdminDataService_Proxy.fetch(AdminDataService_Proxy.java:52) [ERROR] at nl.kees.test.db.client.util.DynamicDataSource.executeFetch(DynamicDataSource.java:90) [ERROR] at nl.kees.test.db.client.util.GwtRpcDataSource.transformRequest(GwtRpcDataSource.java:105) [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [ERROR] at java.lang.reflect.Method.invoke(Method.java:592) [ERROR] at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103) [ERROR] at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71) [ERROR] at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:157) [ERROR] at com.google.gwt.dev.shell.BrowserChannel.reactToMessages(BrowserChannel.java:1668) [ERROR] at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:401) [ERROR] at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:222) [ERROR] at java.lang.Thread.run(Thread.java:595)
I read somewhere that since GWT 2.0 (which I'm using), the IsSerializable is re-introduced instead of the regular Serializable, which might make this old example to crash?
Does anyone have this working (GWT-RPC fetching with Criteria) in GWT 2.0?
Thanks for any help!
Regards,
Kees.
Comment