import java.util.Iterator;
-import org.hibernate.Session;
-import org.splat.dal.dao.kernel.Database;
-
-
public abstract class Relation extends Any {
// Persistent fields
* @param nowner the document to which this relation is moved
* */
public void moveTo (Entity nowner) {
-// ----------------------------------
- Session session = Database.getSession();
+ //RKV Session session = Database.getCurSession();
this.owner = nowner;
nowner.getAllRelations().add(this);
// myold.getAllRelations().remove(this); Harmful as it leads to remove this relation from the database (!?)
- session.update(this);
- session.update(nowner);
+ //RKV session.update(this);
+ //RKV session.update(nowner);
if (this.isBidirectional()) {
Relation link = this.getReverse();
link.setTo(nowner);
- session.update(link);
+ //RKV session.update(link);
}
}