Re: Inherited exceptions in GWT-RPC

2011-09-06 Thread Ryan
Thanks, Colin. I'll double-check my module file and make sure the exceptions are being included for the GWT compiler. That may be the reason they're being missed. On Sep 1, 2:14 pm, Colin Alworth niloc...@gmail.com wrote: On Thursday, August 25, 2011 3:09:22 PM UTC-5, Ryan wrote: However, if

Re: Inherited exceptions in GWT-RPC

2011-09-01 Thread Colin Alworth
On Thursday, August 25, 2011 3:09:22 PM UTC-5, Ryan wrote: However, if I declare AException in the client, but throw either of the two child classes in the server, GWT wraps it in an InvocationException. This is the key to your issue - if the client can't de-serialize it (because the

Re: Inherited exceptions in GWT-RPC

2011-08-31 Thread Ryan
On Aug 26, 12:51 am, Paul Robinson ukcue...@gmail.com wrote: You shouldn't need to do anything. It should work as you thought. That is, you can throw any subclass of the declared exception(s). Is there something about BException and CException that stops them from being gwt-serializable?

Re: Inherited exceptions in GWT-RPC

2011-08-26 Thread Paul Robinson
You shouldn't need to do anything. It should work as you thought. That is, you can throw any subclass of the declared exception(s). Is there something about BException and CException that stops them from being gwt-serializable? Alternatively, maybe it's because AException extends

Inherited exceptions in GWT-RPC

2011-08-25 Thread Ryan
My understanding is that in GWT-RPC, if a service throws an exception declared in the signature, then GWT will report that exception back to the client as-is. If it's any other exception that's thrown, then GWT wraps it in an InvocationException. I have a hierarchy of exceptions that could get

Re: Customizing Serialization process for exceptions In GWT

2010-11-15 Thread keyboard_samurai
Can anyone atleast let me know if what i am looking at is feasible in first place. Thank you! On Nov 14, 3:16 pm, keyboard_samurai yog...@gmail.com wrote: Hi, I am curious to find out if we can override few features in GWT to achieve the following :- In GWT if we want an exception to be

Customizing Serialization process for exceptions In GWT

2010-11-14 Thread keyboard_samurai
Hi, I am curious to find out if we can override few features in GWT to achieve the following :- In GWT if we want an exception to be propagated to the client, the interfaces (extending RemoteService) should have the throws explicitly declared. In our project we have an exception hierarchy defined

Serializing Exceptions with GWT-RPC

2009-08-04 Thread davis
Hi, I have tried the following: public class UserNotFoundException extends Exception implements Serializable { // serial uid private static final long serialVersionUID = 1L; public UserNotFoundException(String msg) { super(msg); } } ...and then in my service interface:

Re: Serializing Exceptions with GWT-RPC

2009-08-04 Thread Paul Robinson
To be gwt-serializable, you must have a no-arg constructor davis wrote: Hi, I have tried the following: public class UserNotFoundException extends Exception implements Serializable { // serial uid private static final long serialVersionUID = 1L; public

Re: Serializing Exceptions with GWT-RPC

2009-08-04 Thread davis
Thanks Paul -- just figured that out. Would be a great time-saver if it told me that explicitly :) On Aug 4, 10:22 am, Paul Robinson ukcue...@gmail.com wrote: To be gwt-serializable, you must have a no-arg constructor davis wrote: Hi, I have tried the following: public class

Re: Exceptions in GWT

2008-09-02 Thread Pierre Mage
Methods defined in the Async interface should not throw exceptions (otherwise you have to surround them by a try catch bloc when using it in your client code) and must have void return types : public void getName(int id,AyncCallback); instead of public String getName(int id,AyncCallback) throws

Exceptions in GWT

2008-08-30 Thread ping2ravi
Hi All, I am having a problem in getting exception messages from exception in onFailure method. My services are like //Client Side public String getName(int id) throws ClientException; public String getName(int id,AyncCallback) throws ClientException; //Server Side public String getName(int