[gradebook2-dev] gb2 and dynamic localization

John Bush john.bush at rsmart.com
Thu Apr 14 17:27:35 PDT 2011


I've been looking into a way to make gb2 integrate with the new
dynamic loading of bundle data available in 2.8.  See
https://jira.sakaiproject.org/browse/SAK-18678.

I see GWT has another method other than the I18nConstants approach
that allows for server side localization:
http://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/google/gwt/i18n/client/Dictionary.html

>From looking at the code switching this out touch almost everything.
So here's my crazy idea.

Use javassist or some other byte code library to get around the fact
that this call can't really be extended:
(I18nMessages) GWT.create(I18nMessages.class);

So basically I'd augment the class that GWT is generating and throw
away what it does and instead delegate all the calls to the
Dictionary, which can then look them up from the server.

Crazy or possible, what do you think?  Going to play around with it a
little tomorrow.

-- 
John Bush
602-490-0470


More information about the gradebook2-dev mailing list