Ok, after reading this blog entry:
http://out-println.blogspot.com/2010/01/hibernate-disabling-all-lazy.htmlI've decided to do something along these lines:
Code:
private static void addInverserAssociationDirection(AnnotationConfiguration annotationConfig){
PersistentClass p = annotationConfig.getClassMapping("E");
Property prop = new Property();
// TODO set attributes
OneToOne oto = new OneToOne(p.getTable(),p);
// TODO set attributes
prop.setValue(oto);
p.addProperty(prop);
}
I'll report back on how it went.