Ask Questions?

View Latest Questions

Advertisement


 
 

Java Notes: Tools
Posted on: July 26, 2006 at 12:00 AM
You need software tools to build Java programs.

Java Notes: Tools

You need software tools to build Java programs. Unless otherwise indicated, all tools mentioned here are freely available, and most of them are open-source.

Sun's Java Software Development Kit
Sun's SDK (formerly known as the JDK - Java Development Kit) is the most commonly used tool to compile and run Java programs. It's a good compiler, but it has a command line user interface. It is typically used with a text editor.
GCJ Compiler
This is an open-source Java compiler. It shouldn't be your first choice. Perhaps the greatest strength of Java is the extensive library. Unfortunately GCJ doesn't support all library classes, most notably the GUI classes. An interesting aspect of GCJ is that it compiles directly to machine code instead of to Java Byte Code. The only reason I include it here is to take part in the online Valladolid Programming Contest you will need to use this compiler.
Text Editors
Text editors are used to write the source programs. Some of them link directly to a compiler, but often you will run the compiler as a separate step to compile the source program.
IDEs - Integrated Development Environments
IDEs contain all the tools that you need to edit, compile, and test , manage projects, etc. An IDE is the high-productivity tool professionals use to produce programs.

Full-strength IDEs (eg NetBeans or Eclipse) are not usually the best choice for beginning students because learning the tool in addition to learning programming can be too much, and perhaps they hide some of the underlying issues of programmin a little too much.

For the intermediate or advanced students it's extremely useful to use an IDE, especially because it can increase your programming productivity, and because it's a useful skill.

UML tools
  • UMLet - (www.umlet.com) = "UMLet is an open-source Java tool for UML diagrams with a light-weight, pop-up-free user interface: draw diagram sketches fast, export diagrams to eps, pdf, jpg, svg, and clipboard, share diagrams using Eclipse, and create custom graphical elements."
  • Violet UML tool - (www.horstmann.com/violet)
    This is a nice simple program for doing class, sequence, and state diagrams. It's written by Cay Horstmann, one of the authors of the wonderful Core Java books, and author of Object-Oriented Design and Patterns. It's free and open source, and can be run from WebStart as well as downloaded.

    This is a nice, simple program with the advantage that you can mess with the source if you really feel like it (only 300KB including the source!).

  • Visual Paradigm for UML - Community Edition (www.visual-paradigm.com)
    The free Community Edition works pretty well. The only restriction that is bothersome is that the company name is printed over diagrams. It required registering, but I've never been hassled by email. After you download it, you will get email with a link to the key file, which you should put into the same directory as the installation file. When asked with you want to install, choose "Paradigm for UML", then "Community Edition".
  • Poseidon for UML - Community Edition (gentleware.com/downloadcenter.0.html)
    I haven't tried this newer version yet.
  • UMLet (www.umlet.com)
    I haven't tried this recently.
  • MagicDraw - Community Edition (http://www.magicdraw.com)
    I've heard good things about it, but haven't tried it yet.
  • NetBeans UML Tool -- Will be in NetBeans 5.5.
Other development tools
As your programs move beyond simple student programs, additional tools will be needed. Some of there are included in IDEs, but many are used independently.
  • Code beautifiers are great for indenting your code correctly. I rarely use them because I'm compulsive about indentation from the beginning, but there are a lot of links at mindprod.com/jgloss/beautifier.html. I've used Arachnophilia, NetBeans, and Artistic Style at various times in the past, but am not sure which is currently the best choice.
  • Style and Correctness Checkers can be used to detect or eliminate problems in your programs.
  • Ant is the Java replacement for the traditional Unix make tool for automating the compilation process. At the simplest, one plain ant command recompiles all source files which have been changed since the last compilation. It can, however, automate all aspects of development.
  • javadoc creates documentation automatically from special comments in your Java programs. It comes with Sun's JDK.
  • JUnit (www.junit.org) is the single most important tool for running unit test cases. Other tools can be used for testing GUI interfaces.
  • Installers.

    There are a number of options if you want to go beyond simply distributing a .jar file of your program. There are a number of installer generators that you can use. Naturally, there are some good commercial installers, but there are also a number of free installers.

    With some installers you can bundle an appropriate version of the JRE (Java Runtime Environment), which will be installed if it's not already on the host machine.

    See Open Source Installers Generators in Java (java-source.net/open-source/installer-generators)

  • PMD (pmd.sourceforge.net) - Checks code for errors. Can run standalone or as a NetBeans plugin.
Copyleft 2006 Fred Swartz MIT License
Advertisement


DMCA.com