Here is the sample xdoc tags i use for the following: (your requirements may differ. 
go thru xdoc docs to figure out which are mandatory and optional) 

CMP Entity bean 
Class Level: 


/**
 * FoodGroupBean is CMP EntityBean implementation that represents 
 * a Food group description record.
 * 
 * @author Venu Narla
 * 
 * @ejb.bean cmp-version="2.x"
 *           description="Food Group Entity Bean"
 *           local-jndi-name="FoodGroupLocalHome"
 *           name="FoodGroup"
 *           schema="FoodGroupSchema"
 *           type="CMP"
 *           view-type="local"
 * @ejb.home local-class="com.togosoft.ht.data.fooddb.FoodGroupLocalHome"
 * @ejb.interface local-class="com.togosoft.ht.data.fooddb.FoodGroupLocal"
 * @ejb.persistence table-name="htFoodGroup_tb"
 * @ejb.pk class="com.togosoft.ht.data.fooddb.FoodGroupPK"
 * @ejb.transaction type="Required"
 * @ejb.value-object name="FoodGroup"
 * @jboss.persistence datasource="java:/HealthTheaterDS"
 *                                datasource-mapping="MS SQLSERVER2000"
 *                                create-table="false"
 *                                        remove-table="false"
 *                                        fetch-size = "1000"
 *                    row-locking="true"
 * 
 * @ejb.finder method-intf = "LocalHome"
 *                         description = "Find all Food Groups"
 *                         query = "SELECT OBJECT(a) FROM FoodGroupSchema AS a"
 *                         signature = "java.util.Collection findAllFoodGroups()"
 * 
 */
public abstract class FoodGroupBean implements EntityBean {

..................




Mehtod Level tags: 
CMP field and pk field

        /**
         * @return
         * @ejb.interface-method
         * @ejb.pk-field 
         * @ejb.persistence column- name="FdGrpCode"
         */
public abstract String getFoodGroupCode();


Method level tags
CMR Field 

        /**
         * @ejb.interface-method
         * @ejb.relation name = "FoodGroup-FoodItems"
     *                           role-name = "FoodGroup-Has-FoodItems"
     *                           target-multiple = "no"
     *                           target-cascade-delete = "yes"
     *                           target-ejb = "FoodItem"  
     *                       target-role-name = "FoodItem-Belongs-To-A-FoodGroup"
     * @jboss.target-relation fk-column = "FdGrpCode_fk"
     *                                            related-pk-field = "foodGroupCode"   
 
         * 
         * @return
         */
public abstract Collection getFoodItems();




Hope this helps

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3842894#3842894

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3842894


-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to