|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.alfresco.repo.domain.permissions.AbstractAclCrudDAOImpl
public abstract class AbstractAclCrudDAOImpl
Abstract implementation for ACL crud DAO.
This provides basic services such as caching, but defers to the underlying implementation for CRUD operations for: alf_access_control_list alf_acl_member alf_acl_change_set alf_access_control_entry alf_permission alf_authority Also, following are currently unused: alf_ace_context alf_authority_alias
Constructor Summary | |
---|---|
AbstractAclCrudDAOImpl()
Default constructor. |
Method Summary | |
---|---|
void |
addAclMembersToAcl(long aclId,
java.util.List aceIdsWithDepths)
|
void |
addAclMembersToAcl(long aclId,
java.util.List aceIds,
int depth)
|
Ace |
createAce(Permission permission,
Authority authority,
ACEType type,
org.alfresco.service.cmr.security.AccessStatus accessStatus)
|
protected abstract long |
createAceContextEntity(AceContextEntity entity)
|
protected abstract long |
createAceEntity(AceEntity entity)
|
AclEntity |
createAcl(AclEntity entity)
|
java.lang.Long |
createAclChangeSet()
|
protected abstract java.lang.Long |
createAclChangeSetEntity()
|
protected abstract AclEntity |
createAclEntity(AclEntity entity)
|
protected abstract AclMemberEntity |
createAclMemberEntity(AclMemberEntity entity)
|
Authority |
createAuthority(java.lang.String authorityName)
|
protected abstract long |
createAuthorityAliasEntity(AuthorityAliasEntity entity)
|
protected abstract AuthorityEntity |
createAuthorityEntity(AuthorityEntity entity)
|
Permission |
createPermission(PermissionReference permissionReference)
|
protected abstract PermissionEntity |
createPermissionEntity(PermissionEntity entity)
|
protected abstract int |
deleteAceContextEntity(long aceContextId)
|
protected abstract int |
deleteAceEntities(java.util.List aceIds)
|
int |
deleteAces(java.util.List aceIds)
|
void |
deleteAcl(long id)
|
void |
deleteAclChangeSet(java.lang.Long changeSetId)
|
protected abstract int |
deleteAclChangeSetEntity(java.lang.Long id)
|
protected abstract int |
deleteAclEntity(long id)
|
protected abstract int |
deleteAclMemberEntities(java.util.List aclMemberIds)
|
protected abstract int |
deleteAclMemberEntitiesByAcl(long idOfAcl)
|
int |
deleteAclMembers(java.util.List aclMemberIds)
|
int |
deleteAclMembersByAcl(long idOfAcl)
|
void |
deleteAuthority(long id)
|
protected abstract int |
deleteAuthorityAliasEntity(long id)
|
protected abstract int |
deleteAuthorityEntity(long id)
|
void |
deletePermission(long id)
|
protected abstract int |
deletePermissionEntity(long id)
|
Ace |
getAce(long aceEntityId)
|
Ace |
getAce(Permission permission,
Authority authority,
ACEType type,
org.alfresco.service.cmr.security.AccessStatus accessStatus)
|
protected abstract java.util.List |
getAceAndAuthorityEntitiesByAcl(long idOfAcl)
|
protected abstract AceContextEntity |
getAceContextEntity(long aceContextId)
|
protected abstract java.util.List |
getAceEntitiesByAuthority(long authorityId)
|
protected abstract AceEntity |
getAceEntity(long aceEntityId)
|
protected abstract AceEntity |
getAceEntity(long permissionId,
long authorityId,
boolean allowed,
ACEType type)
|
java.util.List |
getAcesAndAuthoritiesByAcl(long idOfAcl)
|
java.util.List |
getAcesByAuthority(long authorityId)
|
Acl |
getAcl(long id)
|
AclChangeSetEntity |
getAclChangeSet(java.lang.Long changeSetId)
|
protected abstract AclChangeSetEntity |
getAclChangeSetEntity(java.lang.Long changeSetId)
|
protected abstract java.util.List |
getAclEntitiesThatInheritFromAcl(long idOfAcl)
|
protected abstract AclEntity |
getAclEntity(long id)
|
AclUpdateEntity |
getAclForUpdate(long id)
|
protected abstract java.util.List |
getAclMemberEntitiesByAcl(long idOfAcl)
|
protected abstract java.util.List |
getAclMemberEntitiesByAuthority(java.lang.String authorityName)
|
java.util.List |
getAclMembersByAcl(long idOfAcl)
|
java.util.List |
getAclMembersByAclForUpdate(long idOfAcl)
|
java.util.List |
getAclMembersByAuthority(java.lang.String authorityName)
|
java.util.List |
getAclsThatInheritFromAcl(long aclEntityId)
|
protected abstract java.util.List |
getADMNodeEntityIdsByAcl(long aclEntityId,
int maxResults)
|
java.util.List |
getADMNodesByAcl(long aclEntityId,
int maxResults)
|
Authority |
getAuthority(long id)
|
Authority |
getAuthority(java.lang.String authorityName)
|
protected abstract AuthorityEntity |
getAuthorityEntity(long id)
|
protected abstract AuthorityEntity |
getAuthorityEntity(java.lang.String authorityName)
|
protected abstract java.util.List |
getAVMNodeEntityIdsByAcl(long aclEntityId,
int maxResults)
|
java.util.List |
getAVMNodesByAcl(long aclEntityId,
int maxResults)
|
java.lang.Long |
getLatestAclByGuid(java.lang.String aclGuid)
|
protected abstract java.lang.Long |
getLatestAclEntityByGuid(java.lang.String aclGuid)
|
Ace |
getOrCreateAce(Permission permission,
Authority authority,
ACEType type,
org.alfresco.service.cmr.security.AccessStatus accessStatus)
|
Authority |
getOrCreateAuthority(java.lang.String name)
|
Permission |
getOrCreatePermission(PermissionReference permissionReference)
|
Permission |
getPermission(long id)
|
Permission |
getPermission(PermissionReference permissionReference)
|
protected abstract PermissionEntity |
getPermissionEntity(long id)
|
protected abstract PermissionEntity |
getPermissionEntity(long qnameId,
java.lang.String name)
|
void |
renameAuthority(java.lang.String before,
java.lang.String after)
|
void |
renamePermission(org.alfresco.service.namespace.QName oldTypeQName,
java.lang.String oldName,
org.alfresco.service.namespace.QName newTypeQName,
java.lang.String newName)
|
void |
setAclEntityCache(org.alfresco.repo.cache.SimpleCache aclEntityCache)
Set the cache to use for alf_access_control_list lookups (optional). |
void |
setAuthorityEntityCache(org.alfresco.repo.cache.SimpleCache authorityEntityCache)
Set the cache to use for alf_authority lookups (optional). |
void |
setBatchSize(int batchSizeOverride)
|
void |
setPermissionEntityCache(org.alfresco.repo.cache.SimpleCache permissionEntityCache)
Set the cache to use for alf_permission lookups (optional). |
void |
setQnameDAO(QNameDAO qnameDAO)
|
void |
updateAcl(AclUpdateEntity entity)
|
void |
updateAclChangeSet(java.lang.Long aclChangeSetEntityId,
long commitTimeMs)
|
protected abstract int |
updateAclEntity(AclEntity entity)
|
void |
updateAclMember(AclMemberEntity entity)
|
protected abstract int |
updateAclMemberEntity(AclMemberEntity entity)
|
protected abstract int |
updateAuthorityEntity(AuthorityEntity updateEntity)
|
protected abstract int |
updateChangeSetEntity(java.lang.Long id,
long commitTimeMs)
|
protected abstract int |
updatePermissionEntity(PermissionEntity updateEntity)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AbstractAclCrudDAOImpl()
This sets up the DAO accessors to bypass any caching to handle the case where the caches are not supplied in the setters.
Method Detail |
---|
public void setQnameDAO(QNameDAO qnameDAO)
public void setBatchSize(int batchSizeOverride)
public void setAclEntityCache(org.alfresco.repo.cache.SimpleCache aclEntityCache)
aclEntityCache
- the cache of IDs to AclEntitiespublic void setAuthorityEntityCache(org.alfresco.repo.cache.SimpleCache authorityEntityCache)
authorityEntityCache
- the cache of IDs to AclEntitiespublic void setPermissionEntityCache(org.alfresco.repo.cache.SimpleCache permissionEntityCache)
permissionEntityCache
- the cache of IDs to PermissionEntitiespublic AclEntity createAcl(AclEntity entity)
createAcl
in interface AclCrudDAO
public Acl getAcl(long id)
getAcl
in interface AclCrudDAO
public AclUpdateEntity getAclForUpdate(long id)
getAclForUpdate
in interface AclCrudDAO
public java.util.List getAclsThatInheritFromAcl(long aclEntityId)
getAclsThatInheritFromAcl
in interface AclCrudDAO
public java.lang.Long getLatestAclByGuid(java.lang.String aclGuid)
getLatestAclByGuid
in interface AclCrudDAO
public java.util.List getADMNodesByAcl(long aclEntityId, int maxResults)
getADMNodesByAcl
in interface AclCrudDAO
public java.util.List getAVMNodesByAcl(long aclEntityId, int maxResults)
getAVMNodesByAcl
in interface AclCrudDAO
public void updateAcl(AclUpdateEntity entity)
updateAcl
in interface AclCrudDAO
public void deleteAcl(long id)
deleteAcl
in interface AclCrudDAO
protected abstract AclEntity createAclEntity(AclEntity entity)
protected abstract AclEntity getAclEntity(long id)
protected abstract java.util.List getAclEntitiesThatInheritFromAcl(long idOfAcl)
protected abstract java.lang.Long getLatestAclEntityByGuid(java.lang.String aclGuid)
protected abstract int updateAclEntity(AclEntity entity)
protected abstract int deleteAclEntity(long id)
protected abstract java.util.List getADMNodeEntityIdsByAcl(long aclEntityId, int maxResults)
protected abstract java.util.List getAVMNodeEntityIdsByAcl(long aclEntityId, int maxResults)
public void addAclMembersToAcl(long aclId, java.util.List aceIds, int depth)
addAclMembersToAcl
in interface AclCrudDAO
public void addAclMembersToAcl(long aclId, java.util.List aceIdsWithDepths)
addAclMembersToAcl
in interface AclCrudDAO
public java.util.List getAclMembersByAcl(long idOfAcl)
getAclMembersByAcl
in interface AclCrudDAO
public java.util.List getAclMembersByAclForUpdate(long idOfAcl)
getAclMembersByAclForUpdate
in interface AclCrudDAO
public java.util.List getAclMembersByAuthority(java.lang.String authorityName)
getAclMembersByAuthority
in interface AclCrudDAO
public void updateAclMember(AclMemberEntity entity)
updateAclMember
in interface AclCrudDAO
public int deleteAclMembers(java.util.List aclMemberIds)
deleteAclMembers
in interface AclCrudDAO
public int deleteAclMembersByAcl(long idOfAcl)
deleteAclMembersByAcl
in interface AclCrudDAO
protected abstract AclMemberEntity createAclMemberEntity(AclMemberEntity entity)
protected abstract java.util.List getAclMemberEntitiesByAcl(long idOfAcl)
protected abstract java.util.List getAclMemberEntitiesByAuthority(java.lang.String authorityName)
protected abstract int updateAclMemberEntity(AclMemberEntity entity)
protected abstract int deleteAclMemberEntities(java.util.List aclMemberIds)
protected abstract int deleteAclMemberEntitiesByAcl(long idOfAcl)
public java.lang.Long createAclChangeSet()
createAclChangeSet
in interface AclCrudDAO
public void updateAclChangeSet(java.lang.Long aclChangeSetEntityId, long commitTimeMs)
updateAclChangeSet
in interface AclCrudDAO
public AclChangeSetEntity getAclChangeSet(java.lang.Long changeSetId)
getAclChangeSet
in interface AclCrudDAO
public void deleteAclChangeSet(java.lang.Long changeSetId)
deleteAclChangeSet
in interface AclCrudDAO
protected abstract java.lang.Long createAclChangeSetEntity()
protected abstract AclChangeSetEntity getAclChangeSetEntity(java.lang.Long changeSetId)
protected abstract int deleteAclChangeSetEntity(java.lang.Long id)
protected abstract int updateChangeSetEntity(java.lang.Long id, long commitTimeMs)
public Ace createAce(Permission permission, Authority authority, ACEType type, org.alfresco.service.cmr.security.AccessStatus accessStatus)
createAce
in interface AclCrudDAO
public Ace getAce(Permission permission, Authority authority, ACEType type, org.alfresco.service.cmr.security.AccessStatus accessStatus)
getAce
in interface AclCrudDAO
public Ace getAce(long aceEntityId)
getAce
in interface AclCrudDAO
public Ace getOrCreateAce(Permission permission, Authority authority, ACEType type, org.alfresco.service.cmr.security.AccessStatus accessStatus)
getOrCreateAce
in interface AclCrudDAO
public java.util.List getAcesByAuthority(long authorityId)
getAcesByAuthority
in interface AclCrudDAO
public java.util.List getAcesAndAuthoritiesByAcl(long idOfAcl)
getAcesAndAuthoritiesByAcl
in interface AclCrudDAO
public int deleteAces(java.util.List aceIds)
deleteAces
in interface AclCrudDAO
protected abstract long createAceEntity(AceEntity entity)
protected abstract AceEntity getAceEntity(long aceEntityId)
protected abstract AceEntity getAceEntity(long permissionId, long authorityId, boolean allowed, ACEType type)
protected abstract java.util.List getAceEntitiesByAuthority(long authorityId)
protected abstract java.util.List getAceAndAuthorityEntitiesByAcl(long idOfAcl)
protected abstract int deleteAceEntities(java.util.List aceIds)
public Permission createPermission(PermissionReference permissionReference)
createPermission
in interface AclCrudDAO
public Permission getPermission(long id)
getPermission
in interface AclCrudDAO
public Permission getPermission(PermissionReference permissionReference)
getPermission
in interface AclCrudDAO
public Permission getOrCreatePermission(PermissionReference permissionReference)
getOrCreatePermission
in interface AclCrudDAO
public void renamePermission(org.alfresco.service.namespace.QName oldTypeQName, java.lang.String oldName, org.alfresco.service.namespace.QName newTypeQName, java.lang.String newName)
renamePermission
in interface AclCrudDAO
public void deletePermission(long id)
deletePermission
in interface AclCrudDAO
protected abstract PermissionEntity createPermissionEntity(PermissionEntity entity)
protected abstract PermissionEntity getPermissionEntity(long id)
protected abstract PermissionEntity getPermissionEntity(long qnameId, java.lang.String name)
protected abstract int updatePermissionEntity(PermissionEntity updateEntity)
protected abstract int deletePermissionEntity(long id)
public Authority createAuthority(java.lang.String authorityName)
public Authority getAuthority(long id)
getAuthority
in interface AclCrudDAO
public Authority getAuthority(java.lang.String authorityName)
getAuthority
in interface AclCrudDAO
public Authority getOrCreateAuthority(java.lang.String name)
getOrCreateAuthority
in interface AclCrudDAO
public void renameAuthority(java.lang.String before, java.lang.String after)
renameAuthority
in interface AclCrudDAO
public void deleteAuthority(long id)
deleteAuthority
in interface AclCrudDAO
protected abstract AuthorityEntity createAuthorityEntity(AuthorityEntity entity)
protected abstract AuthorityEntity getAuthorityEntity(long id)
protected abstract AuthorityEntity getAuthorityEntity(java.lang.String authorityName)
protected abstract int updateAuthorityEntity(AuthorityEntity updateEntity)
protected abstract int deleteAuthorityEntity(long id)
protected abstract long createAceContextEntity(AceContextEntity entity)
protected abstract AceContextEntity getAceContextEntity(long aceContextId)
protected abstract int deleteAceContextEntity(long aceContextId)
protected abstract long createAuthorityAliasEntity(AuthorityAliasEntity entity)
protected abstract int deleteAuthorityAliasEntity(long id)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |