2011-09-22

OO Limits of GWT and why GWT is not Java

In GWT to achieve inheritance of UI elements, using the @UiChild annotation is encouraged. But using this technique also makes it impossible to use classic Java inheritance within Composites (Widgets) which apply the @UiChild pattern. As Presenter and View elements (MVP) are necessarily mixed in your *.java files, you can't apply Java's OO inheritance pattern to the Presenter logic as well, or at least GWT makes it unnecessarily complicated to do this. Applying Java's inheritance model leads to a significant increase of the re-compilation time (turnaround time) in GWT's Developer Mode. All these has a huge impact on code re-usage which isn't possible as well as it would be, when GWT would make it easier to apply Java's classic OO inheritance.
...waiting for Dart to bring a significant improvement to GWT in this respect!