@Override
public String processCall(String payload) throws SerializationException {
boolean validSession = (!getThreadLocalRequest().getSession().isNew());
RPCRequest rpcRequest = RPC.decodeRequest(payload, this.remoteServiceClass);
if(!validSession && !rpcRequest.getMethod().getName().equalsIgnoreCase("isUserLoggedIn")){
return RPC.encodeResponseForFailure(null, new IncompatibleRemoteServiceException("Logged out"));
}else{
return super.processCall(payload);
}
}
In your service interface you have do declare each function throws your custom exception otherwise you will get that error.
--
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/-/KuhUBhSNs6wJ.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
May also be a good idea to have all your services declare "throws SerializationException" and have all your custom exceptions extend SerExcJoe, did you fix your problem? if not, can you provide more details?
--
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/-/X58L95r2KDwJ.
--
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/-/7pjmY6KxjVcJ.