Welcome!

Java Authors: Maureen O'Gara, Liz McMillan, Walter H. Pinson, III, Yakov Werde, Tony Bishop

Related Topics: Java

Java: Article

Review: JBuilder 2005 by Borland Software Corporation

Review: JBuilder 2005 by Borland Software Corporation

There is an old joke in which a man is seen coming from a conservation area with a hefty catch of fish. After noticing the proficiency of the fisherman when others had come back empty-handed, a park ranger decides to tag along with him. When they get to a specific location, the fisherman lights a stick of dynamite and throws it in the water, retrieving a huge quantity of fish. While the ranger begins to explain the illegal nature of the fisherman's actions, the man lights another stick, hands it to the ranger, and says, "Do you want to talk?...or do you want to fish?" Borland, with JBuilder, seems to ask a similar question, "Do you want to play, arrange, and mess with your development environment?...or do you want to code?"

It isn't possible to provide an in-depth review of all of JBuilder's features in this short article. While preparing to write this review, I downloaded JBuilder 2005's feature matrix and found it was 32 pages! This article reviews JBuilder 2005 Enterprise Edition, which was released to the public August 2004. However, since I was in the group of beta testers, I had used JBuilder 2005 for several months prior to its public release.

Editor Features
Significant improvements can be found in the editor. MemberInsight has been updated to become Smart MemberInsight. Instead of the drop-down displaying all methods for a given object, it's filtered to the most likely candidates. This can be very confusing at first and takes some getting use to. Depressing ctl+h will expand the filtered list to all possibilities. Key mappings can be adjusted to provide the previous behavior.

ErrorInsight is fairly new in JBuilder and provides a welcomed approach to agile development. Essentially, any errors written in code will be highlighted by ErrorInsight flags. Alt+enter invokes the ErrorInsight to provide options; for example, when used with a TDD approach, referencing classes that don't exist yet causes JBuilder to ask if it should search for the reference or create a new class. Similarly, if a method is used that throws an exception, the provided options (depending on code location) are "Add Throws Clause," "Add Catch Clause," and "Surround with Try/Catch" (see Figure 1).

Development help can also be gleaned from code audit. This new feature highlights potential concerns. For instance, a comparison of two strings with the "==" operator is usually a mistake. With code audits, this code is highlighted with a description of the issue. This feature can get annoying depending on code style. For instance, it complains that code after an if statement needs to be in a code body. Each of these audits can be configured on a project-by-project basis, but again illustrates another deficiency: there doesn't appear to be a way to export and import preferred audit lists for a department so it can be used in another project. Hopefully this will be extended in the future to work like ErrorInsight. If the tool knows that code audit's preference is to put code in a code block after an if statement, why doesn't it assist with that? This is still a welcome feature though as many projects spend thousands of dollars on products for this specific item.

It should be mentioned that some of the best features of JBuilder are not intuitively obvious, like intelligent code editing. For instance, the smart paste feature, through refactoring, cuts several lines of code and pastes them in another class, and JBuilder asks if the associated imports should be added.

JDK 5
A noteworthy must-have for JBuilder 2005 is its support for JDK 5. Provided support includes help identifying conflict issues for situations in which you name a variable enum (which is now a keyword). It also provides support for generics, foreach, autoboxing, and the added Javadoc tags. It even provides a refactoring wizard to migrate iterating loops to the new foreach approach. However, its JDK 5 support isn't complete: among the deficiencies is the lack of support for static imports.

Web Development
The largest collection of must-have features for JBuilder 2005 is that which includes the Web development tools. They provide support for JSP 2.0 and Servlet 2.4 through support for Tomcat 5.0, including JSR 45 debugging support for debugging JSP pages, JavaServer Faces, and Web services enhancements.

JavaServer Faces support was initially a disappointment. However, during Borland's conference the developer of the tool demonstrated some otherwise hidden features in JBuilder, which raised the level of value that JBuilder provides for JSF development. While most other editors are providing design-time WYSIWYG GUI tools for JSF, JBuilder doesn't. The upside to this approach isn't self-evident. The JSF specification doesn't standardize tool support, so whatever tool you use, it has its own proprietary approach for designing JSF. The pro with JBuilder is it doesn't lock you in and you can use JBuilder to work on projects originating in another editor. The downside is WYSIWYG is nice and isn't available here. Of course, maybe we should be upset with the JCP on this one. JBuilder's JSF support is geared to work specifically with the reference implementation from Sun. I've had some success in getting it to work with MyFaces implementation, but you give up some features when doing so.

The tag component palette initially seems like a bad idea, at least for seasoned developers, as it takes up valuable screen real estate and provides little value...until you drag a "smart" component onto a JSP page (I'm still not sure how to distinguish the smart tags from the dumb tags). Try adding a JSF Input Text Form Row to a JSP page; it knows that it's required to be in a form and that form must be in a view. The text in the editor will dynamically change depending on its placement to ensure the nesting of tags is correct. Looking at Figure 2, the inserted tag knows it needs more tags in order to work. It also knows that it already is in the view tag, which would also be inserted if it weren't present. Very cool. With the added benefit of Tag Insight (which essentially is ErrorInsight for tags), the Web development benefits for 2005 make it worth the upgrade.

Additional Features
One of my favorite new features doesn't seem to be documented in what's new. JBuilder now refactors references in XML to classes, which are refactored. This means that struts-config.xml, web.xml, and all the EJB XML files are correctly updated when a class is renamed or repackaged. This is a huge time-saver.

Other new features worth the upgrade: Web services WS-I testing tools, distributed refactoring, debugging Ant and Ant tasks, and Subversion support.

What to Do...What to Do
The Foundation Edition is a free download from Borland and includes many of the editor features as well as most of the refactoring tools. Notably missing is any Web development or EJB development tools. This edition is a good choice for beginners, organizations that aren't doing Web or enterprise development, or those environments that are using other tools for enterprise development such as xDoclet.

The Developer Edition packs the punch in this release. If you're not doing EJB, CORBA, or Web services development, most of the best features exist in this version.

Of course, if you're like me and you don't know what your next server will be, you have to maintain multiple servers and you don't want to waste time tinkering with configurations, or you need one or more the following - Web services tools, advanced OptimizeIT tools (Thread debugger), advanced XML tools, or advanced JUnit tests - you'll need to get the Enterprise Edition. This is the best option for less tinkering and more coding.

More Stories By Ken Sipe

Ken Sipe is the CEO and founder of Code Mentor, Inc. He provides coding, mentoring, and training in OOAD and Java technologies. In addition, Ken is an internationally recognized speaker in the field of distributed computing, speaking often at JavaOne, NFJS, and BorCon.

Comments (2) View Comments

Share your thoughts on this story.

Add your comment
You must be signed in to add a comment. Sign-in | Register

In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.


Most Recent Comments
Peter Carr 02/09/05 04:33:46 PM EST

I installed JBuilder 2005 Foundation on a WinXP Pro system which I already had Java 1.5 and Eclipse 3.0.1 and Eclipse 3.1M4.

After installing JBuilder, my Eclipse wouldn't start.

Apparently the JBuilder installer makes modifications to the registry.

To fix the problem I had to regedit,
HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment\CurrentVersion=1.5

JBuilder installer silently changed this setting to 1.4.

Doychin Bondzhev 01/07/05 02:01:55 AM EST

There is now support for JBoss 4.0 which was added as part of Update 3. Also The full support for J2EE 1.4 was added with this update plus support Sun App server 8