It works!!! Thanks!! > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] Behalf Of > [EMAIL PROTECTED] > Sent: den 17 november 2003 16:05 > To: [EMAIL PROTECTED] > Subject: Re: [Xdoclet-user] Problem with PK-field > > > Hi Dan, > > please try this: > > * @ejb.bean > * name = "MyBean" > * type = "CMP" > * transaction-type = "Container" > * jndi-name="ejb/MyBean" > * local-jndi-name = "ejb/MyBean" > * view-type = "local" > * primkey-field="id" > public abstract class MyBean implements EntityBean { > > // ... // > > /** > * @ejb.pk-field > * @ejb.persistence > * column-name="id" > * jdbc-type="INTEGER" > * sql-type="INT" > * @ejb.interface-method > * @ejb.transaction > * type="Supports" > * @return > */ > public abstract int getId(); > public abstract void setId(int id); > > > // ... // > } > > Good luck, > > Regards, > > Harm de Laat > Informatiefabriek > The Netherlands > > > > > Dan Lagn�hed <[EMAIL PROTECTED]> > Sent by: [EMAIL PROTECTED] > 11/17/2003 03:06 PM > Please respond to > [EMAIL PROTECTED] > > > To > <[EMAIL PROTECTED]> > cc > > Subject > [Xdoclet-user] Problem with PK-field > > > > > > > Hi! > > I'm trying to figure out how to use XDoclet for generating my > entity-beans. I want my bean to use a field called id with type > java.lang.Integer as my primary-key. To accomplish this I'm using > these lines of code: > > /** > * > * @ejb.persistent-field > * @ejb.pk-field > * @ejb.interface-method view-type="local" > */ > public abstract Integer getId(); > > public abstract void setId(Integer id); > > Also, in the comment of this class I have the tag: > > @ejb.pk generate="false" > > > The problem is (everything works just fine except this) that my > ejb-jar.xml file is generated with the entity-tag : > > <prim-key-class>se.brainiac.domain.TMemberPK</prim-key-class> > > I want the prim-key-class to be java.lang.Integer. What am I doing > wrong???? > > Thanks, > Dan Lagnohed > > > > > > ------------------------------------------------------- > This SF. Net email is sponsored by: GoToMyPC > GoToMyPC is the fast, easy and secure way to access your computer from > any Web browser or wireless device. Click here to Try it Free! > https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target=mm/g22lp.tmpl > _______________________________________________ > xdoclet-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/xdoclet-user > > > > > ------------------------------------------------------- > This SF. Net email is sponsored by: GoToMyPC > GoToMyPC is the fast, easy and secure way to access your computer from > any Web browser or wireless device. Click here to Try it Free! > https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target________ _______________________________________ xdoclet-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/xdoclet-user
------------------------------------------------------- This SF. Net email is sponsored by: GoToMyPC GoToMyPC is the fast, easy and secure way to access your computer from any Web browser or wireless device. Click here to Try it Free! https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target=mm/g22lp.tmpl _______________________________________________ xdoclet-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/xdoclet-user
