Related Tools

XDoclet's popularity has resulted in a number of related tools and APIs.

XDoclet Team

XJavaDoc

XJavaDoc is a clone of Sun's JavaDoc core. It is used by XDoclet and provides faster parsing of Java source files than Sun's JavaDoc.

XJavaDoc is also used by XDoclet GUI. XDoclet GUI takes advantage of XJavaDoc's code mutation capabilities (it can modify @tags programmatically).

Here is an example usage of the XJavaDoc API:

// Get a class
XClass fooBar = XJavaDoc.getInstance().getClass("foo.Bar");
// Get a method
XMethod doIt = clazz.getMethod("doIt(java.lang.String[],int)");
// Get the javadoc
XDoc doItDoc = doIt.getDoc();
// Get the value of a tag attribute
XTag zap = doItDoc.getTag("zap");
String zapBang = zap.getAttributeValue("bang");

XJavaDoc resides in a separate xjavadoc module in XDoclet's CVS tree.

XDoclet GUI

XDoclet GUI is a tag editor for existing source code. It provides a structured view of java classes and documentation tags. It utilizes formal tag descriptions (xtags) contained in xdoclet modules and will allow you to insert tags only into appropriate classes/methods. While at the moment XDoclet GUI is a standalone tool, plugins for specific IDEs such as Eclipse, IDEA, Forte/Netbeans, JBuilder etc. can be developed in future.

Click to zoom
Click to zoom

Source code is available in the XDoclet CVS, under the xdocletgui module.

Third Party

Middlegen

Middlegen is a free general-purpose database-driven code generation engine based on JDBC , Velocity , Ant and XDoclet . If you already have a database, you can use Middlegen to generate...

  • EJB (CMP 2.0)
  • JDO
  • JSP/Struts

Middlegen will (among other things) relieve you from the headaches involved with @ejb.relation tags.

UML2EJB

Did you ever think: "mmm... all this EJB stuff is too complex! There must be an easier way to program?" Read the good news: UML2EJB is here to help you! Generating EJBs quickly and reliably from models drawn in the graphical Unified Modeling Language is the main feature of UML2EJB .

MockDoclet

MockDoclet is an active code generation tool for automatically generating mock objects implementation classes from existing classes or interfaces in Java.

AppFuse

AppFuse : an application meant to demonstrate how to use XDoclet with Struts to generate your Forms, web.xml, struts-config.xml, and validation.xml. It's also designed to show how you can use the different security packages (i.e. form-based authentication, SSLExt) and advanced Struts techniques (i.e. Tiles, Validator) to build your webapps.

xPetStore

xPetStore : using XDoclet to implement Sun Microsystems' Java Pet Store J2EE BluePrint Application, this application is the ultimate example of XDoclet's power. Also uses Struts and SiteMesh .