Class AbstractPermissionChangePatch
- java.lang.Object
-
- org.alfresco.repo.admin.patch.AbstractPatch
-
- org.alfresco.repo.admin.patch.impl.AbstractPermissionChangePatch
-
- All Implemented Interfaces:
Patch,org.springframework.beans.factory.Aware,org.springframework.context.ApplicationEventPublisherAware
public abstract class AbstractPermissionChangePatch extends AbstractPatch
Provides common functionality to change a permission type and/or name.- Author:
- Derek Hulley
-
-
Field Summary
-
Fields inherited from class org.alfresco.repo.admin.patch.AbstractPatch
applicationEventPublisher, authenticationContext, ERR_PROPERTY_NOT_SET, namespaceService, nodeService, patchService, searchService, tenantAdminService, transactionHelper, transactionService
-
-
Constructor Summary
Constructors Constructor Description AbstractPermissionChangePatch()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected intrenamePermission(org.alfresco.service.namespace.QName oldTypeQName, java.lang.String oldName, org.alfresco.service.namespace.QName newTypeQName, java.lang.String newName)Helper method to rename (move) a permission.voidsetAclCrudDAO(AclCrudDAO aclCrudDAO)-
Methods inherited from class org.alfresco.repo.admin.patch.AbstractPatch
applies, apply, applyAsync, applyInternal, checkProperties, checkPropertyNotNull, getAlternatives, getDependsOn, getDescription, getFixesFromSchema, getFixesToSchema, getId, getTargetSchema, init, isDeferred, isForce, isIgnored, reportProgress, requiresTransaction, setAlternatives, setApplicationEventPublisher, setApplyToTenants, setAuthenticationContext, setDeferred, setDependsOn, setDescription, setFixesFromSchema, setFixesToSchema, setForce, setId, setIgnored, setNamespaceService, setNodeService, setPatchService, setRequiresTransaction, setSearchService, setTargetSchema, setTenantAdminService, setTransactionService, toString
-
-
-
-
Method Detail
-
setAclCrudDAO
public void setAclCrudDAO(AclCrudDAO aclCrudDAO)
-
renamePermission
protected int renamePermission(org.alfresco.service.namespace.QName oldTypeQName, java.lang.String oldName, org.alfresco.service.namespace.QName newTypeQName, java.lang.String newName)Helper method to rename (move) a permission. This involves checking for the existence of the new permission and then moving all the entries to point to the new permission.- Parameters:
oldTypeQName- the old permission typeoldName- the old permission namenewTypeQName- the new permission typenewName- the new permission name- Returns:
- Returns the number of permission entries modified
-
-