<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
<!-- $Revision: 1.1.2.3 $ -->
<ejb-jar >

   <description><![CDATA[No Description.]]></description>
   <display-name>Generated by XDoclet</display-name>

   <enterprise-beans>

      <!-- Session Beans -->
         <session>
         <description>JUnit Session Bean Test Runner</description>
         <ejb-name>EJBTestRunnerEJB</ejb-name>
         <home>net.sourceforge.junitejb.EJBTestRunnerHome</home>
         <remote>net.sourceforge.junitejb.EJBTestRunner</remote>
         <ejb-class>net.sourceforge.junitejb.EJBTestRunnerBean</ejb-class>
         <session-type>Stateless</session-type>
         <transaction-type>Bean</transaction-type>
      </session>

      <!-- Entity Beans -->
      <entity >
         <description><![CDATA[Test the dbindex feature]]></description>

         <ejb-name>DBIndexTest</ejb-name>

         <local-home>org.jboss.test.cmp2.idxandusersql.ejb.DBIndexTestLocalHome</local-home>
         <local>org.jboss.test.cmp2.idxandusersql.ejb.DBIndexTestLocal</local>

         <ejb-class>org.jboss.test.cmp2.idxandusersql.ejb.DBIndexTestCMP</ejb-class>
         <persistence-type>Container</persistence-type>
         <prim-key-class>java.lang.String</prim-key-class>
         <reentrant>False</reentrant>
         <cmp-version>2.x</cmp-version>
         <abstract-schema-name>DBIndexTest</abstract-schema-name>
         <cmp-field >
            <description><![CDATA[]]></description>
            <field-name>pKey</field-name>
         </cmp-field>
         <cmp-field >
		 <description><![CDATA[This should get an index through <dbindex/>]]></description>
            <field-name>foo</field-name>
         </cmp-field>
         <cmp-field >
		 <description><![CDATA[This should get an index through <post-table-create/>]]></description>
            <field-name>bar</field-name>
         </cmp-field>
         <cmp-field >
		 <description><![CDATA[This one should not be indexed]]></description>
            <field-name>baz</field-name>
         </cmp-field>
         <primkey-field>pKey</primkey-field>
      </entity>

      <entity >
         <description><![CDATA[Test the dbindex feature]]></description>

         <ejb-name>CMR1</ejb-name>

         <local-home>org.jboss.test.cmp2.idxandusersql.ejb.CMR1LocalHome</local-home>
         <local>org.jboss.test.cmp2.idxandusersql.ejb.CMR1Local</local>

         <ejb-class>org.jboss.test.cmp2.idxandusersql.ejb.CMR1CMP</ejb-class>
         <persistence-type>Container</persistence-type>
         <prim-key-class>java.lang.String</prim-key-class>
         <reentrant>False</reentrant>
         <cmp-version>2.x</cmp-version>
         <abstract-schema-name>CMR1</abstract-schema-name>
         <cmp-field >
            <description><![CDATA[]]></description>
            <field-name>pKey</field-name>
         </cmp-field>
         <cmp-field >
		 <description><![CDATA[This should get an index through <dbindex/>]]></description>
            <field-name>foo1</field-name>
         </cmp-field>
         <cmp-field >
		 <description><![CDATA[This should not be indexed]]></description>
            <field-name>bar1</field-name>
         </cmp-field>
         <primkey-field>pKey</primkey-field>
      </entity>

      <entity >
         <description><![CDATA[Test the dbindex feature]]></description>

         <ejb-name>CMR2</ejb-name>

         <local-home>org.jboss.test.cmp2.idxandusersql.ejb.CMR2LocalHome</local-home>
         <local>org.jboss.test.cmp2.idxandusersql.ejb.CMR2Local</local>

         <ejb-class>org.jboss.test.cmp2.idxandusersql.ejb.CMR2CMP</ejb-class>
         <persistence-type>Container</persistence-type>
         <prim-key-class>java.lang.String</prim-key-class>
         <reentrant>False</reentrant>
         <cmp-version>2.x</cmp-version>
         <abstract-schema-name>CMR2</abstract-schema-name>
         <cmp-field >
            <description><![CDATA[]]></description>
            <field-name>pKey2</field-name>
         </cmp-field>
         <cmp-field >
		 <description><![CDATA[This should get an index through <dbindex/>]]></description>
            <field-name>foo2</field-name>
         </cmp-field>
         <cmp-field >
		 <description><![CDATA[This should not be indexed]]></description>
            <field-name>bar2</field-name>
         </cmp-field>
         <primkey-field>pKey2</primkey-field>

	  <!-- Write a file named ejb-finders-DBIndexTestBean.xml if you want to define extra finders. -->
      </entity>

     <!--
       To add entity beans that you have deployment descriptor info for, add
       a file to your XDoclet merge directory called entity-beans.xml that contains
       the <entity></entity> markup for those beans.
     -->

      <!-- Message Driven Beans -->
     <!--
       To add message driven beans that you have deployment descriptor info for, add
       a file to your XDoclet merge directory called message-driven-beans.xml that contains
       the <message-driven></message-driven> markup for those beans.
     -->

   </enterprise-beans>

   <!-- Relationships -->
   <relationships >
      <ejb-relation >
         <ejb-relation-name>IDX-TO-CMR1-RELATION</ejb-relation-name>

         <ejb-relationship-role >
            <ejb-relationship-role-name>cmr1-has-idx</ejb-relationship-role-name>
            <multiplicity>Many</multiplicity>
            <relationship-role-source >
               <ejb-name>CMR1</ejb-name>
            </relationship-role-source>
            <cmr-field >
               <cmr-field-name>idx</cmr-field-name>
            </cmr-field>
         </ejb-relationship-role>

         <ejb-relationship-role >
            <ejb-relationship-role-name>idx-has-cmr1</ejb-relationship-role-name>
            <multiplicity>One</multiplicity>
            <relationship-role-source >
		    <ejb-name>DBIndexTest</ejb-name>
            </relationship-role-source>
            <cmr-field >
               <cmr-field-name>cmr1s</cmr-field-name>
               <cmr-field-type>java.util.Collection</cmr-field-type>
            </cmr-field>
         </ejb-relationship-role>

      </ejb-relation>
     <ejb-relation >
         <ejb-relation-name>IDX-CMR2</ejb-relation-name>

         <ejb-relationship-role >
		 <ejb-relationship-role-name>IDX-has-CMR2s</ejb-relationship-role-name>
            <multiplicity>Many</multiplicity>
            <relationship-role-source >
               <ejb-name>DBIndexTest</ejb-name>
            </relationship-role-source>
            <cmr-field >
               <cmr-field-name>cmr2s</cmr-field-name>
               <cmr-field-type>java.util.Collection</cmr-field-type>
            </cmr-field>
         </ejb-relationship-role>

         <ejb-relationship-role >
		 <ejb-relationship-role-name>CMR2-has-IDXs</ejb-relationship-role-name>
            <multiplicity>Many</multiplicity>
            <relationship-role-source >
               <ejb-name>CMR2</ejb-name>
            </relationship-role-source>
            <cmr-field >
               <cmr-field-name>idxs</cmr-field-name>
               <cmr-field-type>java.util.Collection</cmr-field-type>
            </cmr-field>
         </ejb-relationship-role>

      </ejb-relation>
  </relationships>


  <assembly-descriptor />

</ejb-jar>
