September 2, 2014
Hot Topics:
RSS RSS feed Download our iPhone app

Java Studio Creator 2 Offers Across the Board Improvement

  • February 2, 2006
  • By Dick Wall
  • Send Email »
  • More Articles »
CSS Editor

Being a developer, I have picked up a fair bit of HTML over the years. In fact, although I might not be able to make a really pretty slick page, I can push out a full well-formed HTML page with some fairly extensive content from scratch without needing to refer to a book.

However, not being a Web designer, the same is not true for CSS. I can muddle my way through editing an existing CSS file, or even copying parts of another CSS file and adapting them, but I would rather avoid it.

For this reason, the CSS editor in Creator 2 is a godsend. In fact, this is another feature that was available for beta testing in 1.0, but it is still very welcome.

The CSS editor can be brought up either on the CSS file in the project, or (perhaps more commonly) by hitting the ... button next to Style in the properties for a control.



Click here for a larger image.

HTTP Monitor

My final pick of useful new stuff is the integrated HTTP monitor. Turn this on in the server properties and it will record all traffic for a session, letting you drill down into individual posts and responses. For debugging a problematic and complex Web app, this is a really nice and welcome feature.

Cleaning Up AJAX

Okay, please forgive the terrible pun, but it does fit. Honestly.

Unless you have been living in a hole for the past 18 months, you probably will have heard of AJAX. The technology and the idea are not new, but the name and the hype are.

AJAX stands for Asynchronous JavaScript And XML, and amounts to nothing more than a clever use of client-side JavaScript code to communicate directly with the server and avoid unnecessary page refreshes and round trips. The result is a more interactive, less "webby" feel to Web applications, and the aim is to make something that approaches desktop levels of interactivity and ease of use available in Web UIs.

It has become popular in the last couple of years in part due to some high profile usage by Google (for gmail, Google maps, and Google suggest) and others. It is also very popular and garners much attention.

The big secret is that it is not very easy. It is not some magic wand you can wave to instantly make much cooler Web apps. In fact, AJAX usually requires a lot of custom JavaScript, careful design and planning (both on the JavaScript side and on the server side), and inevitably lots of debugging (Firefox with the Venkman debugger is probably the best option here) and maintenance. You also bump up against some of the classic problems in JavaScript programming—browser incompatibility and other unforeseen circumstances.

The Creator Way

So, AJAX is really hot, but a bit hard and labor intensive. This sounds like a perfect place to apply Java components.

Indeed, this is exactly what Creator is doing in version 2.0. There are four early examples of AJAX components now available from the update center in Creator. For full instructions of how to use these, see http://developers.sun.com/prodtech/javatools/jscreator/reference/techart/2/ajax_samples.pdf, which describes all about how to update, install, and use the four example components.

These four components, while useful in their own right, will hopefully serve as an example for Web and AJAX developers to crystallize the idea of componentized AJAX for JSF. In particular, the Google maps component is a shining example of what AJAX component inclusion in a Web UI should be:



Click here for a larger image.

The really noteworthy things here are the ease with which points of interest (markers), zoom level, and center of map can be controlled by binding values in easily using the creator binding model for components. In a nutshell, this is AJAX usage without having to look at or deal with any JavaScript. Instead of learning an API to use AJAX components, just drop them on the page, resize them, and bind the required properties to values from a database, EJB, data structure, or some other source.

In truth, there is an extra step for using the Google maps component: You have to register to get an API key first. (This is a requirement Google places on the use of the map API, so is unavoidable.) The other three components (auto-complete text field, select value text field, and progress bar) are just as easy to include/bind without needing the extra step of obtaining a key.

This is the best handling of AJAX in a Web UI framework/IDE I have yet seen. It pushes all of the responsibility for creating, debugging, and testing the AJAX component onto the content creator, and then provides a component wrapper that you can pick up and use without needing to even glance at an API reference document.

In short, I think the handling of AJAX in Creator is exactly where it needs to be. I also hope that it gets AJAX library creators excited enough to start providing Creator components that can easily be included.

AJAX is a hot topic right now, and a useful technology when used well. I can see this being one of the big "tractor" technologies that get people interested in Creator 2.0 and trying it out. In the long run, though, I think it is the other technologies and the sheer speed and ease of development that will keep them using the tool.

Conclusion

Java Studio Creator 2.0 is a great update to the original 1.0 version in every way. Better components, faster more solid feeling UI, better base (NetBeans 4.1), many new features and tools, and EJB inclusion add to the overall improvement. The approach to providing AJAX components is extremely compelling, and I hope this alone is enough to generate a lot of interest in the tool.

Certainly, anyone who is thinking of jumping ship to one of the new breed of dynamic language-based Web UI creation systems—such as TurboGears, Django, or Ruby on Rails—would do well to include Java Studio Creator 2.0 in their comparison. I don't say "use it;" I merely say "don't overlook it." The speed of development and ease of use are compelling, and at the same time you can leverage any Java language and library knowledge you already have, and still use a nice rich IDE with good editing, debugging, and diagnostic support.

Java Studio Creator 2.0 is free with a free Sun Developer Network registration. It is available for the Windows, Linux, Solaris, and Mac OS X platforms. Get it here: http://developers.sun.com/prodtech/javatools/jscreator/.

About the Author

Dick Wall is a Principal Systems Engineer for NewEnergy Associates, A Siemens Company based in Atlanta, GA that provides energy IT and consulting solutions for decision support and energy operations. He can be reached for comment on this and other matters at dick.wall@newenergyassoc.com. He also co-hosts The Java Posse, a podcast devoted to Java news and the Java community, which can be found at http://javaposse.com





Page 2 of 2



Comment and Contribute

 


(Maximum characters: 1200). You have characters left.

 

 


Sitemap | Contact Us

Rocket Fuel