On Being a Valuable Newsgroup Contributor

I’ve been a newsgroup junkie for years, and have observed all sorts of interesting behavior. I’ve seen many users come and go. Along the way I’ve learned a lot about how to be a successful and helpful member of the newsgroup community. Here’s a tongue in cheek list of things we can all do to support the community of developers in the Borland newsgroups:

Post Test messages in groups other than the .test groups – One way to really show everyone that you are a veteran newsgroup user is to post a message in a technical group that says “Test – please ignore”. Pay no attention to the test groups.

Crosspost a message that starts out with “I know I’m not supposed to cross-post, but….” – This is one of my personal favorites. The newsgroup guidelines ask you not to crosspost. But you know better, so do it anyway. No one will mind, especially the person that takes the time to answer your question in one group, only to find that it’s already been answered in another. Their time isn’t important, and your time is, after all.

Post a message containing something like this: “It would be easy/cheap for Borland to add to Delphi.” — After all, what the heck does Borland know? Sure, they’ve been in business for twenty years through thick and thin. They’ve been developing and selling software tools successfully for all that time. But that doesn’t mean that they know what they are doing, does it? I mean, they clearly need your advice. Clearly they don’t have any idea what amazing profits would result from instituting your brilliant idea. After all, it’s stunningly amazing that you aren’t running a major corporation.

Relentlessly, endlessly, tirelessly, ubiquitously, ceaselessly, constantly, interminably, monotonously, perpetually crusade for some lost cause. — Figure out what you want, and then pester Borland for it no matter what. Pay no attention to the reasonable, rational arguments about why Borland wouldn’t or shouldn’t do it! Ignore the fact that doing it might drive Borland out of business! Be undetered by people pointing out that you’ve made your point and it might be time to move on. Steer completely unrelated threads and discussions over to your topic. Why would anyone want to talk about anything except what you want to talk about?

Argue with Danny Thorpe about most anything concerning the compiler – Danny may be one of the guys that writes the compiler, but what the heck does he know? You plan for changing the Delphi compiler could probably be easily instituted over the weekend, and would undoubtedly triple Delphi sales.

SHOUT OUT YOUR MESSAGE or use lots of exclamation points!!!!!!!!!!!! — No one can hear you unless you do.

Berate someone about their English or point out typos and misspellings. — This is really key to winning friends and influencing people. Most folks respect and admire you for pointing out trivial typos and misspellings. Doing so will earn accolades. This is especially true if the typist is a non-native speaker. Be sure to berate them about their lack of English skills and point out how ignorant they sound. Doing this will earn you the respect and admiration of all the other non-native English speakers in the groups.

State your opinion as a fact – You are right anyway, so why bother with the caveat of “In my view…”.

Post code that doesn’t compile, or even illustrate the problem – Most everyone on the groups pretty much knows what the problem is after the first sentence, so there’s really no need to post code. And if you do post some code, make sure that you just hack it out in your newsreader so that it doesn’t compile. No one that wants to help will actually read the code anyway.

Spend all your time making cheap comments from the peanut gallery – This is particularly effective in the *.non-technical groups. Don’t ever make a persuasive argument or assert a well-made thought. Instead, just read a few messages in a thread, post a couple of snide, off-the-cuff responses, and then pay no attention to any reason. People will think you are a genius.

Use the F-word and other vulgar language – Nothing says “Hey, I’m a mature professional” like using vulgar language in the newsgroups. Nothing.

Just a few friendly tips to get you started on being a valuable newsgroup contributor.

What’s New in JBuilder 2005?

JBuilder changes so fast that many developers simply don’t keep up. After all, how much improvement can happen over 9 or even 18 months? A lot! This session shows you what you’ve been missing if you are still using an old version of JBuilder. It covers the new features included in both JBuilderX and JBuilder 2005, running the gamut from IDE improvements for coding to the new wizards to simplify complex tasks like web services, EJB development, and Java Server Faces. Throughout this tutorial, I will point out new features and in which version they first appeared.

However, this tutorial is more that just a laundry list of the new features of JBuilder. It is really an exploration on how to use this state-of-the-art IDE to become more productive, no matter what kind of Java development you do. Through this tutorial, I’ll show you lots of tricks and techniques (some of which have been around for many versions) that many long-time developers still don’t know about.

IDE Enhancements

Every version of JBuilder features new, sometimes subtle changes to the IDE.


Since JBuilderX, JBuilder has offered personalities in the IDE. This allows users the turn off functionality that they don’t need on a daily basis. For example, if you never do CORBA development, you can have JBuilder hide the CORBA features. Personalities are accessible from the Project | Properties dialog or from Tools | Preferences.


Personalities allow you to customize the environment to your liking

If you choose this setting from the project properties, it only hides the features for this project. If you set it through the Tools menu, it affects the entire IDE.

Note that de-selecting one of these items does not uninstall this feature — it simply hides it. Thus, this does not make JBuilder’s footprint smaller. It only hides the features in which you have no interest.

Settings Import

JBuilder 2005 prompts for and imports the settings you have set for a previous version of JBuilder. This removes one of the common busy tasks

Support for Java 5

JBuilder 2005 now supports Java 5 (formerly known as Tiger) in the editor and compiler. You can install JDK 1.5 into the JDK’s in JBuilder and build projects using the new language features such as enumerations and generics. The editor correctly parses the new syntax and allows you to work with Java 5 effortlessly.


JBuilder 2005 supports Java 5 syntax and concepts.

Editor Enhancements

Over time, the JBuilder editor has grown some amazing features. In JBuilderX and 2005, that trend has continued. This section highlights some of those enhancements.

Code Folding

JBuilder now allows you to fold code at the method, class, and JavaDoc level. This allows you to compress the file to see just the methods, which is handy when navigating large source files. Of course, you can click on the icon in the gutter to flow code. You can also use the Edit | Code Folding menu.


The Edit menu allows you to handle code folding.

JBuilder also allows you to mouse over the folded code to see what is hidden in a tooltip.

Project-wide To-do’s and Bookmarks

JBuilder now allows you to consolidate your ToDo tags into a single pane. For many versions, JBuilder has supported the special @ToDo JavaDoc tags, both in the code it generates (to remind you to implement methods, for example) and for your own notes to yourself. JBuilder now allows you to see a view of all the ToDo’s, project wide. If you go to Search | View ToDo’s, a new pane opens at the bottom, showing all the ToDo’s in the project.


The Search menu allows you to view project-wide ToDo’s.

Similarly, you can now set project-wide editor bookmarks and get a comprehensive listing of them, via the Search | Bookmarks view. Also, you can invoke Search | Add Bookmark to create new ones outside the editor pane. Here is the listing of the current bookmarks.


The Bookmarks dialog allows you to see all current editor bookmarks.

Tree-based Configuration Dialogs

The Tools | Preferences and Editor Preferences dialogs were getting quite busy with the tabbed interface. Starting in JBuilderX, the configuration dialogs are now tree-based.


The Preferences dialogs use left-hand trees for categorization.

You will also notice that the Tools | Preferences dialog and the Project Properties dialog both appear in the same view. You can still access the project properties independently if you like, but this is handy for those time when you don’t remember whether a setting is project wide or IDE-wide. A single configuration dialog handles both.

New Editor Wizards

The Wizards top-level menu has been demoted to a sub-menu under Edit in JBuilder 2005. The same options are still available, including Override Methods and Implement Interface.


The Edit | Wizards dialog features several important helpers.

Two of the most under-utilized features of JBuilder are the wizards for Override Methods and Implement Interface. A new entry here is the Delegate to Member wizard. This allows you to create a delegate method for one of the member variables in your class. Here is an example. Consider this listing class, which includes a java.util.List member variable named myList.

Simple Lister Class

public class Lister {
    private List myList = new ArrayList();
    public Lister() {
        myList.add("BorCon 2004");
        myList.add("JBuilder 2005");
    public String toString() {
        StringBuffer buf = new StringBuffer(100);
        for (Iterator it = myList.iterator(); it.hasNext(); )
        return buf.toString();
    public static void main(String[] args) {
        Lister lister = new Lister();

The Edit | Wizards | Delegate to Member wizard allows me to choose which method I want to delegate to the Lister class from the embedded object.


The Delegate to Member Wizard

In this case, I choose the add() method from the Collection interface (which is one of the base interfaces behind List). The wizard adds the following method to my class.

Delegate Method Added by Wizard

     * Delegate method boolean add() to myList : List
     * @param o Object
     * @return boolean
    public boolean add(Object o) {
        return myList.add(o);

This wizard is a powerful code generation tool that handles a common necessity. Just like the other code generation wizards, this one can save an enormous amount of time searching through class definitions and typing code by hand.


The productivity category is a catch-all for general enhancements that don’t really fit into other categories.

Regular Expressions in Search and Replace

The Find dialog in JBuilder has featured regular expressions for several versions. What’s new in this version if the ability to use regular expressions in searches across files. This is a really powerful feature because it allows you to investigate files in a large project in a discriminating way.

Improved Twilight Theme!

OK, this doesn’t mean much to most people, but I’m a big fan of the Twilight editor theme, and it was broken in JBuilder 9 (the text remained black on a black background). The Twilight theme has been fixed and improved in the last 2 versions of JBuilder. Actually, from talking to JBuilder developers and users, it seems that the use of the Twilight theme is a bit of a cult — it seems to pop up for everyone in a particular company. In other words, once developers start using it, they "infect" other developers around them. You should try it. The dark background with light text is actually easier on your eyes after a full day of staring at the computer screen. White background is fine for paper (which is reflected light), but fatiguing for generated light (like a monitor). Twilight makes your eyes less tired at the end of the day.

Hotkeys and Keymaps

The keymapping functionality has improved with new features for importing, exporting, saving, renaming, removing, copying, and creating new keymaps. When you open the Preferences dialog box (Tools|Preferences) and choose Keymaps, you can view the New, Copy, Rename, Remove, Import, and Save As buttons on the Keymaps page. This allows you to customize the keymappings and save them for others.


The Keymaps allow you to customize and save keymappings.

File Status

When a file has been modified, the icon in the Project pane changes to show that a change occurred. Also, the status "propagates" up the package viewer to the top, so that you can tell at a glance if any files in a package have changed.


The project pane shows changed files.

Support for Subversion

Many developers use CVS as their version control package because it is freely available and has a long established reputation. However, CVS has serious shortcomings because of the way it was originally implemented. A few years ago, several CVS experts decided to "fix" CVS, and realized that the only way to fix it was to replace it. The end result is Subversion, which supports the features of CVS but none of the shortcomings. Subversion is an open source version control package available at www.tigris.org. It is widely regarded as the successor to CVS in the open source SCCM space. Of course, Subversion doesn’t offer the breadth and depth of commercial products (like StarTeam), but it is the best of the open source packages.

JBuilder 2005 now has first-class support for Subversion. First, set Subversion as the project VCS. When you start to add a project to the repository, use the Team | Place project in Subversion menu item, which presents this dialog:


Subversion repository chooser dialog.

Notice that JBuilder 2005 supports both local and remote repositories. You will also note that JBuilder is adding the project’s last path portion as "trunk". This is a Subversion best practice, related to how Subversion handles project URL’s.

Next, you choose which files to add to the repository.


The Subversion dialog allows you to choose which files to add to the repository.

Once the project is in Subversion, the Project pane changes to show the status for each file in the repository. As changes are made, the project manager notifies you icons. At any time, you can look at the changes to a particular file and compare them to the version in the repository.


JBuilder allows you to make comparisons to the repository.

Favorite new Hotkeys
  • Window | Switch Project (Alt + <n>) Switches between open projects with a hotkey
  • Toggle visible whitespace (Ctrl-Shift-X) Toggle the display of visible whitespace (a good way to tell if you have tabs or spaces in your file)
  • Widening Code Selection (Ctrl-W) Gradually widens the selection of highlighted code

New Features in JBuilder 2005 Part III

J2EE Enhancements

Most of the changes in the Java world for the last few years revolve around enterprise API’s. Similarly, the changes in JBuilder reflect that as well. JBuilder has turned into a J2EE power house, delivering productivity tools for all aspects of enterprise development. This section looks at the changes in JBuilder’s J2EE support in versions 10 and 11 (JBuilderX and JBuilder 2005), starting with EJB and moving to web development. The newest kid on the block, Java Server Faces, has its own section later.


EJB support gets better in each version, and it goes beyond just adding support for new versions of servers. The designers for EJB components now make the sometimes dauntingly complex EJB development much simpler. The general visual designer allows you to create beans for a particular module (which corresponds to an EJB JAR file), add methods, set attributes, and perform all the necessary tasks all through the designer.


The JBuilder 2005 EJB Designer.

No matter how sophisticated the designer, the ultimate artifact created by the designer is the Java source files and the myriad XML configuration files that accompany them. JBuilder 2005 has improved the deployment descriptor editor for the times that you want to make changes directly in the XML documents.

JBuilder features excellent support for CMP 2.0 entity beans. The designer allows you to create a database connection, then builds the CMP based on the meta-data gathered from the database.


The EJB wizard in JBuilder 2005 allows easy creation of CMP entity beans.

The support for CMP goes beyond just the easy creation of single CMP beans. The EJB specification allows you to create related beans, where a single Collection field in one can point to another entity. The designers in JBuilder 2005 allow you to easily create this relationship as well.


The CMP bean designer allows you to add relationships.

However intelligent the designer is, it cannot determine what the relationship between the tables is without intervention. The designer makes a good guess based on column names and field types. Unfortunately, in this case, it guesses incorrectly for one of the columns. If you click on the new field created for the parent side of the relationship (in this case, Orders), you will see that it has created a link between both order_key (which is correct) and comment (which isn’t).


The relationship designer guess incorrectly about the relationship between tables.

To solve this minor problems, right click on the "orderlineitems" field in the Orders table, clear the relationships, and create the correct one.


Correcting the relationship is easy.

New Deployment Descriptor Editor

All XML configuration files in JBuilder have undergone the same face lift. One of the trends in J2EE development is the heavy reliance on XML. so updating the XML configuration editor in JBuilder touches many areas. When modifying an EJB deployment descriptor by hand, you get both code insight and a property editor for setting values.

The new XML Deployment Descriptor editor features a property editor on the right.

Updated Integration for App Servers

Every version of JBuilder supports the latest application servers, and JBuilder 2005 is no exception. JBuilder now supports the following application servers (and versions):

  • Borland Enterprise Server AppServer Edition 5.2 .1
  • Borland Enterprise Server AppServer Edition 6.0
  • JBoss 3.x+
  • Tomcat 4.1
  • Tomcat 5.0
  • Weblogic Application Server 7.x
  • Weblogic Platform Server 8.x
  • Websphere Application Server 5.x
  • Websphere Application Server Advanced Edition 4.0
  • Websphere Application Server Single Server 4.0
  • Generic Appserver 1.0

The Generic Appserver appears to handle the case where you need to utilize an unsupported server. For example, it is easy to setup JBuilder to use the JRun servlet engine by filling in the appropriate values in the Generic Appserver setup.

The main distinction between the different server setups lies in the "Custom" tab. Each server has specific settings it requires for paths, parameters, logins, etc. The custom tab allows JBuilder to adhere exactly with the requirements for a particular server.

JBoss Integration

In versions of JBuilder prior to JBuilderX, integration with the JBoss open-source application server used a custom plug-in. Starting with JBuilderX and extending to JBuilder 2005, JBoss is a first class citizen in JBuilder. The setup for this (and all the other servers) has moved to the Enterprise menu, under Configure Servers.


JBoss is now integrated with JBuilder’s other application servers

Web Development

Web development has always been a strong suit of JBuilder, and JBuilder 2005 continues in that tradition. Several improvements appear in JBuilder 2005 for building web applications, using standard Java technologies (such as JSP 2.0 and Java Server Faces) and support for open-source frameworks.

Web Modules

Starting with JBuilderX, JBuilder replaced the old web nodes with Web Modules. Web Modules more closely mimic the structure and semantics of a WAR file, which is ultimately what web projects need to build. Operationally, they are similar to the old nodes, but have greater flexibility on placing files and seeing them in the root directory of the web application.


The Module gives you more control over the web root directory.

Better Editor Support

JBuilder 2005 has better support for editing both JSP and the ubiquitous XML documents. You get code insight on XML documents (including Ant build files) and tag-specific code insight on JSP pages. For example, if you have included JSTL in our application, the Code Insight shows you JSTL tags, including information about how to use it.


The JSP editor is tag-aware.

The JSP editor also has a new design surface. As seen above, all the visual design surfaces in JBuilder 2005 have been upgraded to the same consistent look. Depending on the types of tags you have added to the JSP, you get categories on the left of the tags. When you select a tag, you can drop it into the JSP page (a moving highlight shows you where it will drop). Then, you can set the attributes of the tag using the property inspector on the right.


The JSP designer now looks like the Swing designer.

JSP development in JBuilder 2005 has gotten much closer to building desktop applications — you now have a component palette, drag and drop components, and a property inspector.

Syntax Highlight for JSP Expression Language

JBuilder 2005 is completely JSP 2.0 expression language aware. It syntax highlights the JSP expressions and provides editor support for using expression language.


The editor now speaks JSP 2.0 expression language.

Struts Designer

The Struts support in JBuilder 2005 makes it very easy to not only create Struts applications but to visualize the flow of information, which is one of the toughest parts of Struts development. JBuilder 2005 allows you to create Struts applications with minimal effort yet allows Struts veterans to build really sophisticated sites.

When you build a new web application with Struts support in JBuilder 2005, you have the option of including both Tiles and the Validation plug-in. JBuilder 2005 includes editors for both of these special purpose XML configuration documents. JBuilder 2005 also includes the Struts 1.1 design editor, which acts as a designer for the underlying struts-config.xml file.


JBuilder 2005 Struts designer makes it easy to modify the struts-config file.

One of the most innovative features of the Struts designer in JBuilder 2005 is the Struts flow designer. Using this designer, you create action classes and visually create the mappings to view resources, form beans, and input pages. When you create an action, the designer shows the action pointing to forward and FormBean placeholders. Clicking on the placeholder allows you to create a new artifact, and the designer allows you to set the relevant properties.


The Action Designer creates visual representations of Struts artifacts.

The design view is even better when you have an ActionForm associated with an action. The designer shows both the incoming and outgoing elements that contribute to the action.


The designer shows a graphical view of the flow of information in the application.

Of course, sometimes it is more convenient to see the details of one of the Struts components in an form view. The form view that has been part of JBuilder since the first support for struts is still here.


The form view shows every possible option for Struts components.

JBuilder 2005 also supports the two standard plug-ins for Struts, tiles and validation. JBuilder 2005 includes a special Tiles editor to help build the tiles.xml document.


The tiles designer eases development using Tiles.

New Features in JBuilder 2005 Part IV

Web Services

Web services continue to be an important technology for developers regardless of platform. JBuilder 2005 includes excellent support for both building and consuming web services.

Web Services Designer

The Web Services designer resembles most of the other non-UI designers in JBuilder 2005 (for example, the EJB designer). It allows you to import a Web Service definition either from a WSDL URL or from UDDI. When you import a WSDL, it creates entries for each exposed object. For example, here is the imported Eliza Chat Bot web service.


The Web Service Designer allows you to import a WSDL.

Consuming a Web Service

To consume a web service, you use the Web Services Designer to import a WSDL for the service you want to call. The Web Services designer creates a project node (much like the other external configuration items, like web modules or EJBs). When you right click on the designer and issue a Make command, it builds all the necessary sources files to make a call to the web service. In fact, it even builds a JUnit test case that shows you how to call the web service! Once you have built the web service, you can make method calls on it just like any other method. Here is the IDE view for the Eliza web service, which is incorporated into a Swing application.


The ClientModule acts as a project node like other designers.

To make the web service method call (after building the web service stub files), you use the Locator as a factory class to create an instance of an object that implements the web service interface. In this example, the ChatLocator acts as a factory to create a chat object. The application allows you to post questions to the chat bot, which she answers.


Chatting with the Eliza Bot.

The code underneath the Ask button makes a call to the web service, passing the question text in the textarea on the top.

Web Service Call to Eliza

public void jButton2_actionPerformed(ActionEvent e) {
    SoapInterop.ChatBindingStub binding;
    try {
        binding = (SoapInterop.ChatBindingStub)
                  new SoapInterop.ChatLocator().getIBaseDataTypes();
    } catch (javax.xml.rpc.ServiceException jre) {
        throw new junit.framework.AssertionFailedError("JAX-RPC ServiceException caught: " + jre);
    try {
    } catch (RemoteException ex) {
Creating Web Services

JBuilder 2005 also makes it easy to create your own web services. To create a Web Service, you first create a project. Then, if you select the option to build a new Web Service (and you don’t yet have a Web Module), JBuilder 2005 will prompt you to create a Web Module. This is the web application that will host your web service.One of the options available allows you to copy the Axis toolkit’s welcome page to your web application (Axis is the open source Web Services toolkit JBuilder 2005 uses).

The next step is to build a Java class whose methods you want to expose as web services. This is a Plain Old Java Object (POJO), which doesn’t implement any special interfaces or extend a certain base class. In this case, it is a very simple Math class.

Simple Math Web Service Class

package borcon_mathws;
public class MathServer {
    public MathServer() {
    public int sum(int op1, int op2) {
        return op1 + op2;

Once you have your class, you associate it with the web service using the designer.


Create a web service based on a simple Java class.

Now, just build the web service node. This generates all the necessary source files to publish your web service. When you run the web application, JBuilder 2005 by default takes you to the Axis Admin page.


The Axis welcome page.

This page allows you to browse web services and administer Axis. If you choose to view web services, it presents a list of the published web services (which includes the MathServer). Clicking on the link for the web service issues an HTTP GET on the web service, to which Axis responds with the WSDL for that web service.


Axis allows you to query the WSDL of your web service.

This web service is now callable from Java, .NET, Ruby, or any other language/platform that supports calling web services. JBuilder 2005 combined with Axis makes building a web service trivial.

Debugging Web Services

The web application built by Axis and JBuilder 2005 is a standard web application, meaning that you can run it in debug mode, using all the debugging features of JBuilder. However, a need still exists to "snoop" on the web traffic between the web application and the client making the web service call. This allows you to debug the SOAP information traveling on the wire. Axis includes a tool called TCP Monitor that allows you to monitor the traffic along TCP. It is included with JBuilder 2005, and shown here.


The TCP Monitor tool lets you watch network activity.

Java Server Faces

One of the most significant new API’s to come from Sun in years is Java Server Faces. It is a new framework for building web applications that allows features that previously was only available in desktop applications. JBuilder 2005 has state-of-the-art support for building JSF applications. When you create a new web application, one of the frameworks available is JSF. When you select JSF, you should also choose JSTL (some of the JSF functionality relies on JSTL features). Once you have created the application, create a new JSP and select the JSF tags. JBuilder 2005 presents you with the JSF designer, which is the updated designer for all user interfaces.


The component drop area is highlighted.

As you can see, when you select a component from the palette on the left, JBuilder 2005 shows you what markup is going to be added in the JSP. Because this is the first JSF component placed on the page, JBuilder 2005 also realizes that the JSF form and view tags are also required, so it adds them as well. For subsequent components, it will only drop the required markup. When you drop a component on the page, ErrorInsight shows the required property values highlighted.


JBuilder 2005 ErrorInsight highlights required components.

Note that JBuilder 2005 uses the JSF tag syntax ("#{…}"), which is close to JSP Expression language syntax ("${…}"). The value property required for the inputTextArea component can either be entered in the JSP source or via the property editor on the right. There are advantages to using the property editor — it will prompt you to create managed components if they don’t yet exist.


The property editor prompts you to create binding components.

When you invoke the dialog from the property editor, it allows you to create managed components, reference existing ones, and create managed properties on the components.


The Value Binding dialog

JBuilder 2005 makes JSF development as easy as building desktop applications. And that is one of the advantages of JSF — creating a RAD framework to make it easier to develop web applications. JSF combined with a tool like JBuilder 2005 takes web development to a new level of productivity.


For whatever reason, developers don’t seem to update JBuilder in every iteration. One of the reasons must be the speed in which new versions appear. However, in every version, new compelling reasons and added functionality keeps it one the cutting edge. JBuilder 2005 has a huge list of updated and added features, and should become a part of every Java developers toolkit.