> Can anyone tell me what the xdoclet tags are for a unidirectional 1-1
> relation between a Customer and an Address in JBoss?
Here it is (debit = customer and adres = address):
/**
* @ejb.interface-method
* @ejb.relation
* name="Debit-Adres"
* role-name="1-debit-1-adres"
* multiple="no"
* target-multiple="no"
* target-cascade-delete="no"
* target-ejb="Adres"
* target-role-name="1-adres-1-debit"
* @jboss.relation
* related-pk-field="adressNr"
* fk-column="adress_nr"
* @jboss.relation-read-ahead strategy="on-find"
*/
public abstract AdresLocal getAdres();
/**
* @ejb.interface-method
*/
public abstract void setAdres( final AdresLocal adres );
Table debit has a field adress_nr as foreign key column.
Adres_nr is the primary key column for table adres.
Joost Kraaijeveld - 11 Apr 2005 21:03 GMT
Hi Frank,
> Here it is (debit = customer and adres = address):
> /**
...
> Table debit has a field adress_nr as foreign key column.
> Adres_nr is the primary key column for table adres.
Thanks for the useful response.
Joost