GWT Conference: Deferred Binding with Ray Cromwell
Ray Cromwell is the CTO of Timepedia, makers of the mega cool Chronoscope. Now we get into the meat of GWT with deferred binding. This area isn't that well documented (though GWT in Action goes cover it a bit).
I won't try to recap Ray's presentation. You can check out his posts, GWT Demystified: Generators (parts one, two, three and erratum) which shows how to expose GWT Pojo's to JavaScript without having to use the messy Ljava/lang/String stuff. He also promised to put a tutorial based on his talk up on his blog. I'll post a link when he does.
There are two types of deferred binding -- Replacement and Generation. If you've used the DOM class, you've used replacement. There are DOMImpl classes for each major browser versions. These replacements account for the typical 4 JavaScript files that GWT produces. If you add internationalization, you will generate even more (4 browsers, 6 languages = 24 JavaScript files). For a little bit of extra disk space, you get JavaScript files that are optimized for a particular language/browser combination. No extra data or code.
Generation gives you, essentially, reflection and code generation (meta programming) at compile time. GWT-RPC, for example, uses generators to...wait for it...generate code to implement the RPC serialization, deserialization, etc.
OK, some Ray Cromwell quotes:
"The Compiler can't optimize code that it hasn't seen."
"The key to deferred bindings is understanding all of the undocumented commands in the Module file."
For more on GWT and deferred binding, see the Rocket-GWT Generator doc.
Technorati Tags: ajax, gwt, deferred binding
Topics: GWT
Leave a comment
About Pathfinder
Follow the Blog
-
Get a monthly update on best practices for delivering successful software.
Subscribe via email
Subscribe via RSS
Categories
Topics
Archives
- July 2009
- June 2009
- May 2009
- April 2009
- March 2009
- February 2009
- January 2009
- December 2008
- November 2008
- October 2008
- September 2008
- August 2008
- July 2008
- June 2008
- May 2008
- April 2008
- March 2008
- February 2008
- January 2008
- December 2007
- November 2007
- October 2007
- September 2007
- August 2007
- July 2007
- June 2007
- May 2007
- April 2007
- March 2007
- February 2007
- January 2007
- December 2006
- November 2006
- October 2006
- September 2006
- August 2006
- July 2006
- June 2006
- May 2006
- April 2006
- March 2006
Blogroll
Recent
- Elements of Testing Style
- Aesthetics and Web Design
- Asterisk-Java Testing with Groovy
- 3 Misuses of Code Comments
- Fluently NHibernate
- Digging a Hole and Covering it with Leaves — The Software Development Version
- The Importance of User Experience - Do You Understand It in Your Bones?
- Writing Your Own Protocol With NSURLProtocol
- What’s In Your Dock: iPhone edition
- Feature Fatigue
