Hi all,
 
I am using XDoclet to generate my Hibernate hbm.xml files. It works perfectly (thanks for the great job to all implied), except with Lightweight classes (http://hibernate.bluemars.net/41.html).
 
To correctly use Lightweight classes, you need to add { polymorphism="explicit" } to your HeavyClass.hbm.xml (otherwize Hibernate will always load the Heavy when you only asked for the Light...). IE : <class name="Customer" table="customers" polymorphism="explicit"> ...
 
My question, how do I add this attribute using XDoclet since the @hibernate.class does not support an polymorphism attribute ?
 
Should I write a feature request (and eventually implement a patch for it), or is there an easier way ?
 
Thanks,
Benoit
 
 
/**
 *
 * @hibernate.class     table="customers"
 */
public class LightCustomer
{
...
}
 
/**
 * @hibernate.class     table="customers"                       [[ MISSING A polymorphism="explicit" ??? ]]
 */
public class Customer extends LightCustomer
{
...
}
 
 
 
ErgoIDP AS
Strandgade 71
DK-1401 Copenhagen K
Denmark
Tel.: +45 32 83 63 00
Fax: +45 32 83 63 01
www.ergoidp.dk 

  

Benoit Voisin                  Direct: +45 32 83 63 16
Software Engineer      
[EMAIL PROTECTED]
 
 

Reply via email to