Free Software and Free Market

Neither Microsoft nor the open source movement participates in the free market. The one side has no interest in money, the other has complete control of its market segment. The end result, however, is the same: indifference to market forces. These two companies show how opposite extremes can tend to mirror one another. But they also show that it is not free markets alone that drive our economy.

For some people the argument that I am making here will sound like heresy. But as I explained in an earlier article entitled "The Drive to Write Free Software," the world isn’t nearly as simple as it appears to be. The free market is a necessary and important part of modern life, but it is only a part of a larger picture.

It is easy to get stuck in the past. It is easy to believe in outdated theories like a pure free market that exists without compromise, and to fail to see that these theories don’t conform to what is happening in the real world. Our minds can’t adapt to the rapid rate of change in the modern world. What we need is not more free rigid theories, but the freedom to use whatever tools work, so long as they don’t violate our sense of ethics and fair play.

In the midst of all this confusion, it is the rare person who recognizes in all this diversity the chaos that makes up the web of life. There is hope in all this diversity. It is precisely this diverse confluence of cacophonous voices that can often best promote innovation.

The true force of innovation doesn’t belong to any one economic theory, but rather to man’s innate desire to evolve and to improve his state. Anything that promotes innovation and the production of much needed, high quality, software is good, so long as it doesn’t violate our moral principles. For instance, there is no reason why free markets can’t learn from the open software movement. Maybe the open source model is better than the closed source model. Why can’t companies like Borland learn from the free software movement in a case like this? Why must they work in secrecy, why can’t they be more open? It’s a proven technique that works for the free software movement, why can’t it work for them?

I personally don’t like monocultures. So sometimes I believe innovation is supported by free markets, sometimes by laws that restrain unfair competition. And yet I can see that sometimes it might be free software that promotes innovation, and sometimes, oddly enough, it might be a monopoly like Microsoft or even a state owned business like the Post Office.

The world isn’t as simple as some might wish, but it sure is a lot simpler if people free themselves from the shackles of their narrow prejudices and ill conceived preconceptions. The bigger, and more open your mind, the easier it is for you to navigate through the rapid change found in the modern world. The enemy isn’t free software, or open source software, or the free market, or even a monopoly. Borland is a great company. And so is Microsoft. But the free software movement has also contributed enormously to our society. The enemy isn’t diversity. The enemy is a chauvinistic logician who thinks she has a theory of everything, whether that theory is called free software, or a free market. The enemy is a rigid, narrow, closed mind.

Ultimately, we can’t prove that free software is better than the free market, that monopolies are always evil, nor that the free market should dominate our economy to the exclusion of all other ways of life. But we can apply our ethics and our sense of fair play to the world around us, and decide which parts of each of these competing theories best suits our sense of what is right and wrong.

Monoculture Software Cycles

One would think that at this point the picture would be complete. On one side stood Borland, the bastion of the secret world of free market software, and on the other end stood the open source movement, the antithesis of everything that Borland represented. But the really shocking thing is that Borland represented a sort of middle ground between what was happening in the open source movement, and its true doppelganger, the Microsoft software development process.

According to free market theory, monopolies are supposed to fail because their employees have no motive to work. With a market share of over 90%, both the Microsoft operating system and its office products fully qualify as monopolies. According to theory, these products should be bad by definition, since they are no longer driven by market forces. But these products were successful both in the marketplace, and in terms of technical prowess. Most versions of a Microsoft Windows or Office represented an improvement over its predecessor, despite the fact that they faced no serious competition. According to unfettered free market theory, Windows XP should have been worse that Windows ME or Windows 2000, or Windows 98. But there is no doubt that Microsoft keeps improving their products, despite the lack of true free market pressures that drives a company like Borland.

Microsoft telegraphs their every move to the world. They don’t, of course, share their source, but the whole world knows the name of most important Microsoft betas, and many of these betas are made fully public to anyone who wants to participate. The exact contents of each product — no, the wildest dreams of even the flakiest project managers — are broadcast as front page news to the world when Microsoft is in a development cycle. Borland works in secret, Microsoft in public.

If something goes wrong during a Borland development cycle, a wall of denial goes up. But at Microsoft, if innovation is dropped because of technical necessity, Microsoft shares the defeat with the entire world. And because it is a monopoly, it suffers these defeats without loosing market share, without loosing market value.

So both Microsoft and the free software movement work in the open, and ship when they want. But there are profound differences between their models. Microsoft does not churn out software five or six times a year like an open source project, nor once or twice a year like Borland. Instead, Microsoft turns out software on a glacially slow schedule. It is not at all uncommon for three to five years to pass between iterations of major Microsoft products such as Windows, Office or MS SQL Server. Nevertheless, neither of them are bound by a fixed length to their development cycle. And neither of them bothers with secrecy. They both make a point of broadcasting their plans to the world years ahead of time.

Free Software Cycles

During the years that Borland developers churned in this cycle like a load of wash in a closed room, another method of developing software was gaining a foothold in the world. This alternative methodology, called the open software movement, produced free software using techniques that radically contrasted with Borland’s methodology. If Borland developers were spinning in an automated drier hidden from the world, then the open source movement was working outdoors, washing their laundry in tubs, and hanging it up to dry on outside lines for all the world to see.

Rather than shipping once a year, the open source movement tended to ship products three or four times a year, and sometimes considerably more frequently. Rather than hiding their work in private betas, the open source community encouraged any one who was interested to download the product and try it out. And not just the product, but the source to the product. There is nothing Borland holds in more profound and shrouded secrecy than the source code to their compilers and IDEs.

Rather than trying to conceal bugs, the open source movement wanted everyone to search for and report bugs. Each flaw was immediately, and often permanently, enshrined in public databases for all the world to see. And they accepted not only bug reports, but actual patches to the software, many of which were fully incorporated into the product. Again, nothing could be in greater contrast to the Borland way of doing business. At Borland, there were times when employees were literally and specifically instructed to never publicly say the word bug. This was not just a denial that there were bugs in the product, but a denial that the very concept of a bug even existed!

Everything that the open source movement did stood in stark contrast to the Borland development methodology. At Borland, the bottom line was business. The free market system was the engine that drove the world of software innovation. Without the free market, no one was supposed to be inclined to do anything. Without the incentive to make money, there was, according to the free market gospel of unfettered capitalism, no reason to work, let alone to innovate.

But oddly enough, the open source movement, which did not charge for its products, produced software at such a rate that they slowly, relentlessly broke into the markets that were formerly dominated by private companies. Technology like the Apache web browser, and innovations like the Perl language, like unit testing, like JBoss, or like the Ant build engine, became so ubiquitous, so transformative, so necessary to the development process, that big companies were forced to adopt free software technologies to better support the world of open source software.

Who can forget the time, two or three years ago, when the statistics appeared showing that MySQL was the only database in the world to meet the performance characteristics of Oracle software? Oracle, the company that had spent untold millions developing the fastest database in the world was suddenly staring into the eyes of a free open source project that two years previously had barely been on anyone’s radar, let alone imagined as a serious competitor.

Free Market Software Cycles

The Borland software cycle is well known to users of their software. At predictable intervals, Borland kicks out new versions of their software. Borland development teams struggle in cloaked secrecy to create a product. Working only with a tiny group of beta testers, the Delphi team usually gives birth in November or December. Whether the product is ready or not, whether it has enough new features or not, regardless of consequences, it will be shipped out to the world each year when the cold winter rains pound the shores of Monterey Bay.

Borland’s Delphi 8 product was buggy, unstable, and incomplete. Many people who follow Borland closely believe Delphi 8 was flawed because the team was forced to ship before they were ready. Delphi 8 had a huge new feature set, and it appears to many that the company did not give the team enough time before forcing them to ship. From a certain point of view, Delphi 8 seems to highlight the flaws in a market system that successful free software teams never face. But let’s not jump to conclusions too quickly.

Consider, for example, the JBuilder team. Twice each year, at sixth month intervals, they ship a version of JBuilder. Sometimes you need to be an expert to detect the difference between one version of JBuilder and the next, but nonetheless the versions keep coming, Over the long term, the JBuilder team, working at this frenetic pace, created a series of remarkably innovative products. From the first iteration of the all Java based JBuilder 4 platform, and on through JBuilder 2005, the team has continued to put out a series of solid products that break new ground. JBuilder had the first widely used all java editor. Innovations followed in refactoring, in code insight, in the editor’s ability to automatically insert try..catch blocks where needed, in its automatic handling of import statements. Again and again JBuilder led the way in programming editor enhancements. And wondrously, the editor worked nearly flawlessly on both Windows and Linux! No other IDE had ever done anything remotely as impressive.

JBuilder’s record proves that there is nothing inherently wrong with Borland’s approach to software development. You can successfully put a team on a break neck schedule, lock them up in near total privacy, and release products beneath a veil of secrecy so thick that at times it seemed like sacrilege to even consider marketing a product which had, during its development, been so carefully hidden from the prying eyes of the world.

Looking at these examples, one can conclude that the market forces driving Borland could successfully create high quality software, but could not guarantee the production of high quality software. But for free market capitalism to meet the claims of its adherents to be the best, and only practical, system, it must not only be successful, but be shown to actually outperform the competition.

Closed Minds, Open Source: Software Cycle Prejudice

Most economic theories are merely dogmatic prejudices which become meaningless in the real world. Nothing stifles our economy more effectively than attempts to apply any single economic theory to everyone in all cases. Instead, real economies must be driven by a combination of compromises struck between opposing forces. Ultimately, it is hard to prove that any one economic theory works to the exclusion of all others. But one can see that there are moral differences between theories.

To illustrate this point, I’ll look at various software release cycles, and see how they are affected by prevailing economic theories. I’ll start by defining in a very general way what we mean by a software cycle. Software products are shipped in cycles. A typical cycle would include at least one iteration of the following pattern: outlining new features, fixing bugs, testing new code, then shipping the product. The next cycle would repeat the same process.


The economic theories discussed in this article are:

  • Free market economies: Here companies compete against each other for market share. In a Darwinian world, only the strongest can survive.
  • Free software: Here people create software for free, and only the needs of users determine which software will thrive.
  • Monocultures: In these markets one company has a monopoly, and no real competition exists. For the purposes of this article, any company that has a 90 percent market share in a particular area will be considered to be a monoculture.

Here is how software cycles are dictated by these economic theories:

  • In free market economies, we are told that economic pressures drive release cycles: Products must ship at certain dates and times to bring in needed revenue, and feature sets bend to conform to schedules.
  • The free software movement, on the other hand, does not have the same economic pressures. It is not forced to ship on a particular schedule, nor are its features sets dictated by economic pressures. Instead, free software ships when a product is ready, and feature sets are dictated by demand, not be enforced schedules.
  • Monocultures, because they exist in a world without competition, can work on the same wide open schedule as the free software movement. They ship when they are ready to ship, and they contain the features that the monopoly deems important or useful.

What does all this tell us about open source software, free software and the free market? Seemingly unquestioned conventional wisdom says that unfettered free market competition is the best possible system because it creates the greatest good for the greatest number of people. It is the best way of motivating people to create both products and wealth. All other systems are supposedly doomed to failure by definition.

Since neither Microsoft nor the free software movement participate in a free market, what does their success say about this economic theory? How much of what we believe is simple prejudice, and how much is founded on events that take place in the real world?

New Features in JBuilder 2005 Part II

The debugger has added a new view to make it easier to look at the values of common collections like List and Map. This viewer displays the selected object as an array. To use this custom viewer, right-click a Map or Collection object in the Threads, call stacks and data view or the Data watches view. Choose Show Custom View, then toArray(java.util.Collection). The object is displayed as an array.


The toArray() view of a List in the Thread view.

The debugger also has a new feature: Quick Step Into. The Run|Quick Step Into command steps directly into the first parameter in the method signature, rather than stepping through the called method. This is also a button on the debugger toolbar.

Debug Ant build files!

Each version of JBuilder adds more and more support for Ant. Two of the most exciting features of JBuilder 2005 for heavy Ant users is the promotion of build files to full blown designable artifacts and the ability to debug Ant build files. When you select an Ant build file in the editor, you see a property view on the right-hand side, just like the other design artifacts in JBuilder.


Ant build file properties have a property editor now.

You can also debug Ant build files now. Click in the left-hand margin (just like a Java source file) and select Debug from the right-click menu on the build file. The Ant debugger shows the current line being executed along with a view of the build file with the current line highlighted.


The debugger provides lots of feedback while debugging build files.

Help Search

One of the welcome productivity enhancements in JBuilder 2005 is a greatly improved Search tab in the help files. The left-hand pane offers a wide variety of options to search within the extensive help documentation.


JBuilder’s Search for help has greatly improved.

Designer Changes

The entire design surface for Swing and Micro development has changed in JBuilder 2005. The component palette now appears on the left of the design surface (rather than the top) and features a new compartmentalized palette.


The visual designers have been updated.

You can now perform an incremental search for a component name at the top of the palette. This makes it much easier to locate a component if you know its name but can’t remember what tab where it resides.


Refactoring quickly becomes a must-have feature for developers, and if you must use an IDE for any time that doesn’t support it (i.e., any non-Java IDE), you sorely miss it. JBuilder has always had strong refactoring support, and it has just gotten better in JBuilder 2005.

Improved Refactoring Menu Structure

All refactorings have now moved into their own menu structure, and context sensitive refactorings appear in the right-click sub-menu in the editor.

New Refactorings

You can rename refactor class names when working in a deployment descriptor file. To do this, right-click the name of the class you want to refactor, choose Refactor To Class, and enter the new class name. When you complete the refactoring, JBuilder will rename the class in all locations it is used and referred to, including deployment descriptors.

Distributed refactoring

JBuilder now records completed refactorings for the current project. You can add this history to the project archive, making the history available to other projects and libraries that were not available in the initial refactoring. You can use the history to easily update projects that depend on refactored external APIs, SDKs and libraries. This feature is called distributed refactoring. To use distributed refactoring, you must first add the refactoring history to the depended-upon project or library’s archive. When you open that depended-upon project or library archive from the dependent project, you can then review all refactorings with the Refactoring History. You will first refactor your project globally so that all files in the project are updated to the new code symbols. You can then use ErrorInsight to refactor any remaining instances of out-of-date code.

Adding the Refactoring History to the Project Archive

You can add the refactoring history to the project archive, so that others who view your project can see what refactorings occurred. They, in turn, can use the Pending Refactorings and Refactoring History dialog boxes to update their code. To do this, choose the Archive Builder (File|New|Archive) for the type of archive you wish to create. On the Specify Refactoring History To Provide page, choose one of the following options:

  • Select the Do Not Include Refactorings option if you do not want any refactoring history added to the archive.
  • Select the Include Content Related Refactorings to add refactorings only in classes that you are adding to the archive. You can use this option if not all classes are being added to the archive.
  • Select the Include All Refactorings to add all refactorings for all classes to the archive.
Refactoring History

The refactoring history is displayed in the Pending Refactorings and Refactoring History dialog boxes (Refactor|Pending Refactorings or Refactor|Refactoring History). Pending refactorings are refactorings in the depended-upon project or library that have not yet been applied to the current project. The Refactoring History dialog box displays a list of all refactorings that have occurred in the current project or in projects or libraries that this project depends on. You can see refactorings that might impact your code and then choose to invoke those refactorings to update your code. You can then choose a refactoring with the Refactor button and invoke that refactoring on your code.

Refactoring to an Existing Symbol

Once you’ve determined that your code is out-of-date, you can refactor your code to an existing code symbol. To do this, you can:

  • Open the Pending Refactorings dialog box (Refactor|Pending Refactorings) and choose a refactoring to invoke, or
  • Open the refactoring history (Refactor|Refactoring History) and choose a refactoring to invoke, or
  • Click the ErrorInsight icon in the gutter next to the outdated symbol and choose the Refactor To command
JDK 5.0 Refactorings

JBuilder now supports JDK 5.0 refactorings that update code to use JDK 5.0 language features. The following refactorings for JDK 5.0 code are supported:

  • Foreach refactorings: Foreach refactorings refactor existing loops to JDK 5.0-style enhanced loops. You can refactor the following types of loops:
    • Array traversal
    • List traversal
    • Iterator for loops
    • Iterator while loops
  • Auto(un)boxing refactorings: The autoboxing and auto-unboxing features in the JDK 5.0 allow you to easily convert between primitive types and their Object-based counterparts.
  • Generics refactorings: JDK 5.0 introduces the use of Generics. Generics add compile-time type safety to the Collections API and eliminate casting. In JDK 1.4 and below, an Object would need to be cast to the appropriate type before usage. With Generics, the need for casting is eliminated.

Here is an example of the Introduce Generics refactoring. Here is a method that iterates over a list of Employee objects, calling an applyRaise() method for each:

Code that Applies Raises

    public void raiseSalaries(List emps) {
        for (int i = 0; i < emps.size(); i++) {
            ((Employee) emps).applyRaise(5);

Now, I’ll apply JDK 5 refactorings for three things:

  • Change the list to Generics
  • Auto-unbox Employee objects
  • Use a foreach loop

For each of these refactorings, I select the code in question and invoke the refactorings.


The Introduce Generics refactoring dialog.

The resulting code has changed to this method:

Refactored Code that Applies Raises

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 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.