objEnt);
createObjRelationship(objEnt, rel);
application.getUndoManager().addEdit(
new CreateRelationshipUndoableEdit(objEnt, new ObjRelationship[] {
rel
}));
}
else {
DbEntity dbEnt = getProjectController().getCurrentDbEntity();
if (dbEnt != null) {
DbRelationship rel = (DbRelationship) NamedObjectFactory.createObject(
DbRelationship.class,
dbEnt);
createDbRelationship(dbEnt, rel);
application.getUndoManager().addEdit(
new CreateRelationshipUndoableEdit(dbEnt, new DbRelationship[] {
rel
}));
}
}
}