Friedrich-Alexander-Universität
Friedrich-Alexander-Universität
Stanford Radiology

Javadoc Generation

Preliminaries

This page is a short tutorial on how to generate the Javadoc documentation for CONRAD. In general, we provide the Javadoc for each version of CONRAD online as webpage or as zip file that can be included into your eclipse setup.

In CONRAD, we are using Opens external link in new windowLaTeXlet a taglet, that allows to embed LaTeX into Javadoc. This allows us to put equations directly into the source code / Javadoc. The equations are rendered by the custom taglet during the generation of the documentation and embedded into the Javadoc. Although this is very convenient, the actual setup requires certain settings in eclipse that may not be straight forward. Therefore, we describe the required steps in the following. Note that you will need a working TeX environment in your path in order to execute this.

Start Javadoc Generation in Eclipse

Use the menubar to start the javadoc generation.

In order to generate the javadoc, a current Java Development Kit (JDK) needs to be installed. Here the API generation is shown using JDK 1.7. Furthermore eclipse needs to be set up such that it is able to compile the CONRAD code (cf. the tutorial on compilation).

Open eclipse and select the Javadoc generation from the menubar. Note that the default setting in the Javadoc generation is, that all packages will be preselected that are already selected in the package explorer. It is useful to select a flat package representation here, as subpackages are not selected automatically in a hierarchical representation.

Setting up Javadoc

The first of three screens that need to be configured to create a javadoc via eclipse.

In the first text field, the javadoc command needs to be entered. In the example on the right, the location is in a default location "C:\Program Files\Java\jdk1.7.0\bin\javadoc.exe".

Furthermore, you need to select the right packages that will be included in the Javadoc. It is useful to do this already in the package explorer before starting the Javadoc generation wizard.

After selecting the standard doclet. You need to specify the path where the Javadoc will be created. We set "D:\src\KONRAD\doc" in the example on the right.

Then, proceed to the next page of the wizard by pressing "Next".

Configure Javadoc Arguments for the Standard Doclet

Second page of the Javadoc creation wizard.

On the second page of the wizard, all settings are correct in default setting shown on the right.

Click "Next" to proceed to the next step.

Configuration of Latexlet as extra Option

On the last page of the creation wizard the latexlet options have to be set correctly in order to create the Javadoc with TeX equations.

On the last page, the options for LaTeXlet need to be specified. In order to get a correct compilation result, a TeX environment needs to be configured in the path. Furthermore, you need to specify the folloing extra options (as shown on the right):

-taglet latexlet.InlineBlockLaTeXlet 

-taglet latexlet.BlockLaTeXlet 

-taglet latexlet.InlineLaTeXlet

-tagletpath $PATH$

Where $PATH$ is the path to your latexlet.jar. This path is configured with "D:\src\lib\LaTeXlet.jar" in this example. Note that we provide a version of this file installation package.

Furthermore, you need to select the right Java version for your Javadoc. We selected "1.7" in the example on the right.

The Javadoc can now be generated by clicking "Finish". The result of such a compilation is found Initiates file downloadhere.