Thursday, August 13, 2015

Creating javadocs without the package name before objects (with and without ant)


This is a simple one but from some reason it took a while to find the solution.

When creatin javadocs, by default each object comes with it package name.
If you don't want to see the package name before each object, use the noqualifier flag (thanks to for the solution)

As ant target

Example Javadoc ant taget

<target name="javadocs" >
    <mkdir dir="${dir.javadocs}"/>

    <javadoc packagenames="com.tzachsolomon.example.*"             sourcepath="-module1/src/main/java:module2/src/main/java"             destdir="${dir.javadocs}"             classpath="module1/src/main/java:module2/src/main/java"
             author="true"             version="true"             use="true"             access="public"             windowtitle="${} API"             encoding="UTF-8"             verbose="false"             noqualifier="all"             doctitle="&lt;h1&gt;${}&lt;/h1&gt;"/>