Why are you using a ResourceBundle within the exception?
new MySuperDuperException(bundle.getKey("blah"));
on client side,
onFailure(Throwable cause) {
MySuperDuperException a = cause;
a.getMessage(); // whatever the localized message is
}
On Thu, Apr 23, 2009 at 6:54 AM, olel <[email protected]> wrote:
>
> > I do understand it. So what exactly prevents you from using a
> > ResourceBundle when you throw the exception on the server side? It's
> > regular Java servlet code - has nothing to do with GWT.
>
> The point isn't that the exception is thrown on server side. The point
> is that it is catch on client side and therefore needs to be
> referenced by the Application.gwt.xml config file as an additional
> source path like "<source path='common/exception' />" (remember that
> GWT needs all sources for the used classes).
> And as java.util.ResourceBundle is imported in the exception class and
> the exception class is imported in the client code (that GWT generates
> JavaScript for) you will get the "no source code available"-error.
> >
>
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---