Hi,

I am also interested in this.

Our approach is to write the texts into the properties files and then
use the GWT-i18n tool to generate the interface-files.
Of course this is not the best thing to do, because all the arguments
will be strings...

Maybe another approach would be to extend the GWT-i18n tool, which
already does the properties file parsing and creates the interface
file.
I have not looked at this tool yet, but maybe it can be extended to
generate another file for the backend, that implements the interface
methods and builds the messages from the ResourceBundle.

regards, martin

On Sep 22, 12:02 pm, Lothar Kimmeringer <[EMAIL PROTECTED]> wrote:
> Dobes schrieb:
>
> > Hm, I see.  But would I be able to use GWT.create(...) to create the
> > Constants subclass, and have it honor my @DefaultStringValue()
> > annotations?
>
> I'm using GWT 1.4 here and haven't migrated to 1.5, yet.
> Using GWT.create will be difficult on the server-side, because
> the Locale can be different for every request, so you need
> a second parameter. Using ResourceBundle on the other side allows
> a similar call:
>
> ResourceBundle rb = 
> ResourceBundle.getBundle(AdminToolsI18NConstants.class.getName(), loc);
>
> > I suppose not, so maybe I'd have to come up with some kind of clever
> > factory scheme which uses GWT.create in client code and whatever my
> > own implementation is in server code.
>
> You can implement your own version of ResourceBundle, that is
> reading in the property-files and use reflection on the interface
> to get the annotations. With Proxy-classes it should also be possible
> to create something similar to GWT.create.
>
> If I have very much time, I'd might be able to program something
> like this, but you shouldn't wait for that, at the moment my spare
> time is about zero ;-)
>
> Regards, Lothar
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to