Java2Html converts Java (and other) source code (complete files or snippets) to HTML, RTF, TeX and XHTML with syntax highlighting.
This open source Java project consists of an extendible library along with a Java application, a Java applet and many plugins in order to integrate the library into other programs.
Example:
/* This is about <code>ClassName</code>.
* {@link com.yourCompany.aPackage.SuperClass}
* @author author
*/
public class ClassName extends SuperClass {
/* This comment may span multiple lines. */
private int integer = 0;
public final static char character = 'A';
// This comment may span only this line
private String string = "zero";
}
See Other Best Code Formatters Projects in Java: