AJAX and Java: Toolbox
Robert Cooper
Nov. 29, 2005 09:43 AM
Permalink
Target Audience: Pretty typical Struts developer looking to enhance functionality without radically redefining the way she builds software.
Ascendancy: Order of invasiveness to your app.
AJAXTags
AJAXTags is a simple JSP taglib that offers some nice functionality. It is not a framework. It is not a methodology. It is, simply, a handful of app-friendly tricks that you can stick into your application. They have a nice demo page demonstrating each of the tags. There is a nice "sliding doors" CSS tabset, an autocomplete widget and a bean-bound table (imagine that :P). If you are like me, a lot of this is stuff that you have built by hand already, but having some standard tags for it is handy.
Taconite
Taconite uses the word "framework", but I wouldn't go that far. The short version is it is a tool that simplifies (a) making your XmlHttpRequest call and (b) gives you server-side markup that controls basic insert parameters.
For instance: If you want a button to append something to the bottom of a content area:
<script>!-- function foo(url){ var ajaxRequest = new AjaxRequest(url); ajaxRequest.sendRequest(); } //--></script>
<button onclick="foo('runButton.action?id=bar');">
</button>
Then your JSP for runButton would have:
<taconite-root space="preserve">
<taconite-append-as-children contextnodeid="idOfNodeToAppendTo" parseinbrowser="true"> </taconite-append-as-children></taconite-root><div style="font-weight: bold; color: orange;">
Taconite says: Hello World!!!
</div>
</taconite-append-as-children>
</taconite-root>
Of course, with some clever breaking up of JSPs, it is not hard to use the same content set for an AJAX and Non-AJAX version of your app.
Direct Web Remoting
The Zipperheads have a nice intro to this. This is the most invasive of anything here. This is basically an easy way to expose a service bean to a web client through JavaScript directly. If you are like me, and tend to build your business services with Axis SOAP in mind, you will find it nearly brain-free to re-expose them as a DWR "JavaScript Service".
Moo.fx
This is just some chrome for your app, but its not bad and is a small and noninvasive way to give your app some polish. It is a set of nicely animated transitions and visibility controls. They have some fancy demos, but if you look at the test page you can see all the individual functions laid out pretty well.
Robert Cooper is an independent Java developer in the Atlanta area, working with J2EE technologies and web/web service projects.
0 Comments:
Post a Comment
<< Home