AVM nodes get a useful version id.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@4727 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Britt Park
2007-01-04 14:59:29 +00:00
parent fcb36d4c4c
commit 0a76193084
8 changed files with 61 additions and 11 deletions

View File

@@ -81,6 +81,14 @@ class LayeredDirectoryNodeImpl extends DirectoryNodeImpl implements LayeredDirec
fIndirection = indirection;
fPrimaryIndirection = true;
fOpacity = false;
if (toCopy != null)
{
setVersionID(toCopy.getVersionID() + 1);
}
else
{
setVersionID(1);
}
AVMDAOs.Instance().fAVMNodeDAO.save(this);
AVMDAOs.Instance().fAVMNodeDAO.flush();
if (toCopy != null)
@@ -113,6 +121,7 @@ class LayeredDirectoryNodeImpl extends DirectoryNodeImpl implements LayeredDirec
child.getChild());
AVMDAOs.Instance().fChildEntryDAO.save(newChild);
}
setVersionID(other.getVersionID() + 1);
AVMDAOs.Instance().fAVMNodeDAO.flush();
copyProperties(other);
copyAspects(other);
@@ -148,6 +157,7 @@ class LayeredDirectoryNodeImpl extends DirectoryNodeImpl implements LayeredDirec
AVMDAOs.Instance().fChildEntryDAO.save(newChild);
}
}
setVersionID(other.getVersionID() + 1);
AVMDAOs.Instance().fAVMNodeDAO.flush();
copyProperties(other);
copyAspects(other);
@@ -172,6 +182,7 @@ class LayeredDirectoryNodeImpl extends DirectoryNodeImpl implements LayeredDirec
fPrimaryIndirection = true;
fLayerID = -1;
fOpacity = false;
setVersionID(dir.getVersionID() + 1);
AVMDAOs.Instance().fAVMNodeDAO.save(this);
AVMDAOs.Instance().fAVMNodeDAO.flush();
copyProperties(dir);