Turns out it was just not catching NullPoiterException. probably
related to the difference between null and undefined
On Oct 28, 5:20 pm, Ravi M <[EMAIL PROTECTED]> wrote:
> Stephen
>
> I _think_ Lothar's point is that MyException needs to extend
> com.google.gwt.user.client.rpc.SerializableException not just
> implement IsSerializable for exceptions across RPC to work properly. I
> had this problem a few weeks back where exceptions thrown across RPC
> were merely IsSerializable and couldn't be caught with the correct
> type in onFailure().
>
> Anyway, looks like you fixed your problem regardless, so I will cease
> and desist.
>
> Regards,
> Ravi
>
> On Oct 21, 9:13 pm, "[EMAIL PROTECTED]"
>
>
>
> <[EMAIL PROTECTED]> wrote:
> > Sorry lothar. to answere your first question, it isnt being caught at
> > all, and MyException extends isSerialisable however as i mentioned i
> > was mistaken, instanceof works perfectly.
>
> > Thank you for taking the time to help develop gwt and for helping me
> > out :)
>
> > On Oct 21, 1:28 pm, Lothar Kimmeringer <[EMAIL PROTECTED]> wrote:
>
> > > [EMAIL PROTECTED] schrieb:
>
> > > > Sorry for reposting but to me this is a critical issue that should be
> > > > looked into asp. Has anyone else had this problem or can someone else
> > > > reproduce it?
>
> > > You haven't answered my question, so I didn't see a reason to look
> > > into that further (nobody is paying me for doing that anyway, so
> > > it's voluntary work anyway).
>
> > > What is
> > > try{
> > > String test = null;
> > > test.toString();}
>
> > > catch(NullPointerException npe){
> > > Window.alert(Boolean.toString(npe instanceof NullPointerException));}
>
> > > returning?
>
> > > > iv also found recently that if i throw an exception MyException from
> > > > the server to the client and do the following in the onFailure method
> > > > the expression evaluates to false.
>
> > > > if (caught instanceof MyException) {
> > > > Window.alert("true");
> > > > } else {
> > > > Window.alert("false");
> > > > }
>
> > > To repeat my question: Is MyException derived from SerializableException?
>
> > > Regards, Lothar- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---