views:

1101

answers:

3

I have created java api -ported from C# to be more specific- which aside from public interface, contains a lot of internal stuff that I don't want a user to know about. In C#, I have used doxygen to generate documentation. I presume javadoc has similar features to exclude certain public members, classes, even packages.

Would someone suggest how do that, perhaps via eclipse?

Thanks

A: 

You can use doxygen with Java. I am not aware of any tools that do what you want with Javadoc.

Superpackages should be coming in JDK 7 which I beleive could address this: http://blogs.sun.com/andreas/entry/superpackages_in_jsr_294

TofuBeer
A: 
VonC
can you please direct me to the tool, thankyou
KiNGPiN
@KiNGPiN: the "other product" was DocFlex/Javadoc (http://www.filigris.com/products/docflex_javadoc/#top)
VonC
+2  A: 

I believe that in Eclipse, the only kind of exclusions you can specify are things like "exclude all protected members" and package-based exclusions (not class-based exclusions.)

If you're using Ant to generate them, you can use the nested "package" element, and you can use a fileset nested element and add exclusions to that fileset.

For example:

<javadoc >
    <sourcefiles>
          <fileset dir="${src}">
              <include name="**/*.java"/>
              <exclude name="**/ClassToExclude.java"/>
          </fileset>
    </sourcefiles>
    <packageset>
          <dirset dir="${src}">
              <include name="com.mydomain.*"/>
              <exclude name="com.mydomain.excludePackage"/>
          </dirset>
     </packageset>
</javadoc>

P.S. - I've used the <sourcefiles> element alot, but never the <packageset> element. The latter might not be spot-on syntactically.

Jared
I have never used ant. Would you quickly describe how to run this file? (i have it installed though) is it ./ant filename
Here's the manual: http://ant.apache.org/manual/index.html
Jared
packageset doesn't support the nested "dirset" element.
Dave Jarvis