mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
This changes PermissionsDaoComponentImpl to work with NodeRefs instead
of Nodes so that Permissions can be used with AVM nodes. It needs to be factored a little bit differently, so consider this a WIP. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3698 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -26,6 +26,7 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.SortedMap;
|
||||
|
||||
import org.alfresco.repo.domain.DbAccessControlList;
|
||||
import org.alfresco.repo.domain.PropertyValue;
|
||||
import org.alfresco.service.cmr.avm.AVMCycleException;
|
||||
import org.alfresco.service.cmr.avm.AVMException;
|
||||
@@ -1139,4 +1140,31 @@ public class AVMRepository
|
||||
AVMStore store = getAVMStoreByName(pathParts[0]);
|
||||
return store.hasAspect(version, pathParts[1], aspectName);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the ACL on a node.
|
||||
* @param path The path to the node.
|
||||
* @param acl The ACL to set.
|
||||
*/
|
||||
public void setACL(String path, DbAccessControlList acl)
|
||||
{
|
||||
fLookupCount.set(1);
|
||||
String [] pathParts = SplitPath(path);
|
||||
AVMStore store = getAVMStoreByName(pathParts[0]);
|
||||
store.setACL(pathParts[1], acl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the ACL on a node.
|
||||
* @param version The version to look under.
|
||||
* @param path The path to the node.
|
||||
* @return The ACL.
|
||||
*/
|
||||
public DbAccessControlList getACL(int version, String path)
|
||||
{
|
||||
fLookupCount.set(1);
|
||||
String [] pathParts = SplitPath(path);
|
||||
AVMStore store = getAVMStoreByName(pathParts[0]);
|
||||
return store.getACL(version, pathParts[1]);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user