Generating UML From the NetBeans IDE by John Zukowski Imagine having been given the source code for a project that needs to be maintained, and the maintainer is long gone. You have the task of adding a new feature. Take a look at what you can discover by using a tool such as the Unified Modeling Language (UML) Modeling module of the NetBeans IDE 5.5 to explore the source code and generate UML diagrams of the system. The abook.zip file includes a project designed by Sun Microsystems. It is a basic address-book management system. Using the NetBeans IDE and the UML Modeling module, you'll discover the objects in this application. First, you need to install NetBeans if you don't have it already. Launch the NetBeans IDE. By default, the UML Modeling Module is not part of the installation, so you must add that after installing and launching the IDE. Go to the Update Center's Tools menu, then click on Update Center to launch the wizard. Figure 1. Update Center Wizard | Make sure you have selected the NetBeans Update Center option. When you select Next, the wizard connects to each Update Center for potential modules to add, such as the UML Modeling one. Although you can also install the UML Bank App Sample module, it is the UML Modeling module under Features that you need to install for this article. Figure 2. UML Modeling Selection | Although the UML Modeling module is only 10 KB, pressing Add with UML Modeling selected will add not only the selected module but all of its dependencies, totaling over 18 MB in this case. Figure 3. Include In Install | Press the Next button at the bottom to add all the necessary modules and get the UML Modeling module, after you accept a few licensing agreements. Figure 4. Download | After the 17 modules, including UML Modeling, are installed, press the Next button to see the list of certificates you must view before installation, and then press Finish. This will prompt you to restart the IDE to install the modules. Figure 5. Restart the IDE | You'll see the IDE exit and restart while it installs everything. Once it has restarted, you can now start analyzing the provided source. To open this project, select the File menu, then the Open Project menu item. You'll need to locate the top-level directory for where you unzipped the ZIP file. For instance, if you unzipped everything to C:\work, select the ABook entry in the C:\work directory, then press the Open Project Folder button. Loading causes a complaint about the derby JAR file not being found. Just click past the problem for now. You're not going to run anything just yet. Read the rest of this article |