Tuesday, May 27, 2008

Wicket vs GWT

Wicket and GWT both use component approach. But it's too different. The Wicket uses a special HTML attribute to denote components, enabling easy editing with ordinary HTML editors. With Wicket you get the benefits of a first-class component model and a non-intrusive approach to HTML. In Wicket, all server side state is automatically managed. For many applications, it will be worth trading off the increased server load of extra server-side state for decreased development costs, lower maintenance costs, quicker time-to-market and generally higher quality software. But the GWT has a different approach to AJAX. The GWT use pour HTML and Java DOM model, to translates your Java application to browser-compliant JavaScript and HTML. Making a heavy use of client browser and minimizing number and size of HTTP requests. With Java to JavaScript translation you should always control your code. In client code you can use only base types. To call service you should create special classes. With service implementation you get 3 files. Two interface where first is for synchrony use, second is for asynchrony use and one implementation. So you have messy code. One of disadvantages is complex structure of modules. Personally I chose Wicket. It impresses me with its simplicity and ability to create reusable panels without any XMLs.