User: ibruell Date: 01/07/13 09:07:14 Modified: src/docs howtoejbdoclet.xml Log: Changed some id's to avoid conflicts. Added some comments. Revision Changes Path 1.3 +45 -24 manual/src/docs/howtoejbdoclet.xml Index: howtoejbdoclet.xml =================================================================== RCS file: /cvsroot/jboss/manual/src/docs/howtoejbdoclet.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- howtoejbdoclet.xml 2001/07/13 09:10:13 1.2 +++ howtoejbdoclet.xml 2001/07/13 16:07:13 1.3 @@ -32,6 +32,10 @@ think the usage of ant is very recommend (and for now the only way to use ejbdoclet!). </para> + <para> + The tools.jar from the j2sdk is needed to call javadoc, so place it in the + classpath, too. + </para> </section> <section id="ejbdoclet-createingthebean"> @@ -46,23 +50,23 @@ /** * This is an account bean. It is an example of how to use the EJBDoclet tags. * - * @ejb:entity-cmp <co id="entity-cmp"/> + * @ejb:entity-cmp <co id="ejbdoclet-entity-cmp"/> * @ejb:ejb-name bank/Account * @ejb:jndi-name ejb/bank/Account - * @ejb:finder Collection findAll() <co id="finder"/> + * @ejb:finder Collection findAll() <co id="ejbdoclet-finder"/> * @ejb:finder Collection findByOwner(Customer owner) * @ejb:finder Collection findLargeAccounts(int balance) - * @ejb:env-entry foo 1234 java.lang.Integer <co id="envvar"/> - * @ejb:ejb-ref bank/Customer <co id="ref"/> + * @ejb:env-entry foo 1234 java.lang.Integer <co id="ejbdoclet-envvar"/> + * @ejb:ejb-ref bank/Customer <co id="ejbdoclet-ref"/> * @ejb:security-role-ref admin Administrator * @ejb:permission Teller * @ejb:transaction Required * @ejb:use-soft-locking * - * JBoss specific <co id="jboss"/> + * JBoss specific <co id="ejbdoclet-jboss"/> * @jboss:container-configuration Standard CMP EntityBean * - * JBoss/JAWS CMP specific <co id="jawsco"/> + * JBoss/JAWS CMP specific <co id="ejbdoclet-jaws"/> * @jboss:table-name account * @jboss:create-table true * @jboss:remove-table true @@ -75,41 +79,41 @@ { </programlisting> <calloutlist> - <callout arearefs="entity-cmp"> + <callout arearefs="ejbdoclet-entity-cmp"> <para> Here is specified that this would be an Entity Bean </para> </callout> - <callout arearefs="finder"> + <callout arearefs="ejbdoclet-finder"> <para> Defining the finder methods </para> </callout> - <callout arearefs="envvar"> + <callout arearefs="ejbdoclet-envvar"> <para> Easy define envelope vars </para> </callout> - <callout arearefs="ref"> + <callout arearefs="ejbdoclet-ref"> <para> Define references to other beans </para> </callout> - <callout arearefs="jboss"> + <callout arearefs="ejbdoclet-jboss"> <para> With these tags you could specify JBoss specific parameters (see EJBDoclet docu for more details about the tags). </para> </callout> - <callout arearefs="jawsco"> + <callout arearefs="ejbdoclet-jaws"> <para> And here you could define JAWS specific parameters (see EJBDoclet docu for more details about the tags). </para> </callout> </calloutlist> - How you can see it is very easy to create the Beanclass. The JBoss and JAWS specific - part should only be used, if the standard values of JBoss not fit. + You can see it is very easy to create the Beanclass. The JBoss and JAWS specific + part should only be used, if the standard values of JBoss do not fit. </para> <para> Now you need to define the method level tags like this: @@ -117,7 +121,7 @@ /** * Create account. * - * @ejb:permission Administrator <co id="permission"/> + * @ejb:permission Administrator <co id="ejbdoclet-permission"/> */ public AccountPK ejbCreate(AccountData data) throws CreateException @@ -133,7 +137,7 @@ * * This is not remote since the primary key can be extracted by other means. * - * @ejb:pk-field <co id="pk"/> + * @ejb:pk-field <co id="ejbdoclet-pk"/> * @ejb:persistent-field * * @jboss:column-name pk @@ -149,8 +153,8 @@ /** * Owner of this account. * - * @ejb:remote-method <co id="remote"/> - * @ejb:persistent-field <co id="persistent"/> + * @ejb:remote-method <co id="ejbdoclet-remote"/> + * @ejb:persistent-field <co id="ejbdoclet-persistent"/> * @ejb:permission Administrator * @ejb:transaction Supports */ @@ -163,22 +167,22 @@ public abstract void setOwner(Customer owner); </programlisting> <calloutlist> - <callout arearefs="permission"> + <callout arearefs="ejbdoclet-permission"> <para> With this tag permissions could be defined at method level </para> </callout> - <callout arearefs="pk"> + <callout arearefs="ejbdoclet-pk"> <para> With @ejb:pk-field a primary key field is defined </para> </callout> - <callout arearefs="remote"> + <callout arearefs="ejbdoclet-remote"> <para> @ejb:remote-method defines a remote method </para> </callout> - <callout arearefs="persistent"> + <callout arearefs="ejbdoclet-persistent"> <para> And @ejb:persistent-field defines an attribute that should be stored persistent. @@ -226,13 +230,13 @@ . . . . +-CustomerBean.java </programlisting> - Here my ant script (build.xml)that generates the beans interfaces and the descriptors + Here my ant script (build.xml) that generates the beans interfaces and the descriptors and after that it compiles the java files and package them into a jar file: <programlisting><![CDATA[ <?xml version="1.0" encoding="ISO-8859-1"?> <!-- - $Revision: 1.2 $ $Date: 2001/07/13 09:10:13 $ $Author: gropi $ + $Revision: 1.3 $ $Date: 2001/07/13 16:07:13 $ $Author: ibruell $ --> <project name="test" default="main" basedir="../.."> @@ -403,6 +407,23 @@ </project> ]]></programlisting> + </para> + <para> + The build.xml generates first PrimaryKey and DataObject classes, Home and + Remote Interfaces and ejb-jar.xml, jboss.xml and jaws.xml descriptors. The + java files are then compiled into the build/classes directory. After that the + files would be archived in test.jar in dist/deploy, however. Now the jar file + could be deployed in jboss. + </para> + + </section> + + <section id="ejbdoclet-concluding"><title>Concluding</title> + + <para> + A brief explanation of all possible parameters and a complete example + you can find in the ejbdoclet archive, that could be downloaded from + <ulink url="http://sf.net/projects/ejbdoclet">sourceforge</ulink>. </para> </section> _______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-development