[ http://opensource.atlassian.com/projects/xdoclet/browse/XDT-1544?page=comments#action_17301 ]
King Henree commented on XDT-1544: ---------------------------------- There seems to have been some misunderstanding with my initial post that I will try to clarify. There are no problems when declaring an @ejb.create-method tag directly within an entity bean. The problem occurs when declaring the @ejb.create-method tag within a plain old Java abstract base class that the entity beans extend to take advantage of the plain Java abtract base class' fields and methods. Take a look at my original post and you will notice that my base class is just a plain old Java abstract class that does not implement javax.ejb.EntityBean. This type of setup works well with @ejb.interface-method and @ejb.persistence tags declared within the plain old Java abstract base class that is extended by entity beans and will put those methods in the XDoclet generated *BeanCMP classes, the remote and local interfaces, and the generated deployment descriptor. The only quirk is that XDoclet has problems generating the create methods within the local/remote home interfaces when @ejb.create-method is declared in the plain old Java abstract base class that the entity beans extend, but XDoclet will generate the correct deployment descriptor (ejb-jar.xml) information under <assembly-descriptor><container-transaction><method> ...blah, blah, blah, ... </method></container-transaction></assembly-descriptor> if you include the @ejb.transaction tag along with the @ejb.create-method tag. Thanks. > XDoclet 1.2.3 is not generating ejbCreate in local/remote home interfaces > ------------------------------------------------------------------------- > > Key: XDT-1544 > URL: http://opensource.atlassian.com/projects/xdoclet/browse/XDT-1544 > Project: XDoclet > Type: Bug > Components: EJB Module > Versions: 1.2.3 > Environment: OS: Windows XP > Java: 1.4.2 and 1.5.0 > Reporter: King Henree > Assignee: xdoclet-devel (Use for new issues) > > > XDoclet: 1.2.3 > I have an abstract base class of which other CMP entity beans extend. I > included the @ejb.create-method tag in my base class, but when I run XDoclet > it will not generate the ejbCreate method within the local home interface. > Ironically, XDoclet will correctly generate the > <container-transaction><method> > ..... > <method-name>create</method-name> > ..... > </method></container-method> > deployment descriptor stuff ok. XDoclet will also generate all the > @ejb.interface-method methods properly within the local interfaces. XDoclet > just won't generate the create method within the local home interface with > @ejb.create-method. How do I fix this? > Thanks. > *********Sample Base & Derived Entity Bean Classes********* > public abstract class MyDataBaseBean { > > /** > * Creates a new instance of MyDataBaseBean > */ > public MyDataBaseBean() { > } > > /** > * @ejb.create-method > * view-type="local" > * @ejb.transaction > * type="Required" > */ > public test.primkeys.MyDataBeanPK ejbCreate(test.MyData myData, > test.localinterfaces.MyDataLocal myDataLocal) throws > javax.ejb.CreateException { > setMyData1(myData.getData1()); > setMyData2(myData.getData2()); > > return null; > } > > public void ejbPostCreate(test.MyData myData, > test.localinterfaces.MyDataLocal myDataLocal) throws > javax.ejb.CreateException { > setMyData(myDataLocal); > } > /** > * @ejb.interface-method > * view-type="local" > * @ejb.persistence > * column-name="high" > */ > public abstract java.math.BigDecimal getHigh(); > public abstract void setHigh(java.math.BigDecimal high); > ......... > } > /** > * @ejb.bean > * name="MyDataABean" > * type="CMP" > * @ejb.pk > * class="test.primkeys.MyDataBeanPK" > * > * @jboss.audit-updated-time > * field-name="updated" > * column-name="updated" > * @jboss.persistence > * table-name="MyDataA" > */ > public abstract class MyDataABean extends MyDataBaseBean implements > javax.ejb.EntityBean { > private javax.ejb.EntityContext context; > ......... > } -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/xdoclet/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl _______________________________________________ xdoclet-devel mailing list xdoclet-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/xdoclet-devel