Configuring Xdoclet for J2ee Applications in Eclipse

For J2EE applications, We can configure Xdoclet in Eclipse so that development can be made faster. Xdoclet can be downloaded from

Extract Xdoclet files to the local drive.

1. First we will configure Xdoclet in Eclipse. For this go to Windows -> Preferences. Just fill Xdoclet home path where you installed Xdoclet. It will look like.


Click “OK” Xdoclet is configured in Eclipse so as to make Enterprise Application Development easy. Now while writing EJB, Hibernate you can use some Xdoclet tags so as to generate Java code like EJB remote interfaces, deployment descriptors etc
A typical XDoclet comment might look like this:

 * This is an account bean. It is an example of how to use the
 * EJBDoclet tags.
 * @see Customer Accounts are owned by customers, and a customer can
 * have many accounts.
 * @ejb:bean   name="bank/Account"
 *             type="CMP"
 *             jndi-name="ejb/bank/Account"
 *             primkey-field="id"
 * @ejb:finder signature="Collection findAll()"
 *             unchecked="true"
 * @ejb:interface remote-class="test.interfaces.Account"