Interface ModelDAO
- All Known Implementing Classes:
PermissionModel
public interface ModelDAO
The API for the alfresco permission model.
- Author:
- Andy Hind
-
Method Summary
Modifier and TypeMethodDescriptionbooleancheckPermission(PermissionReference required) Is this permission refernece to a permission and not a permissoinSet?Get all exposed permissions (regardless of type exposure)Get all exposed permissions (regardless of type exposure)getAllPermissions(NodeRef nodeRef) Get the permissions that can be set for the given node.getAllPermissions(QName type) Get the permissions that can be set for the given type.getAllPermissions(QName type, Set<QName> aspects) Get the permissions that can be set for the given type.getExposedPermissions(NodeRef nodeRef) Get the permissions that are exposed to be set for the given node.getExposedPermissions(QName type) Get the permissions that are exposed to be set for the given type.Set<? extends PermissionEntry>Get the global permissions for the model.getGranteePermissions(PermissionReference permissionReference) Get the permissions which are granted by the supplied permission.Get all the permissions that grant this permission.getImmediateGranteePermissions(PermissionReference permissionReference) Get the permissions which are granted by the supplied permission.getPermissionReference(QName qname, String permissionName) Find a permission by name in the type context.getRequiredPermissions(PermissionReference required, QName qName, Set<QName> aspectQNames, RequiredPermission.On on) Get the permissions that must also be present on the node for the required permission to apply.booleanhasFull(PermissionReference permissionReference) Does this permission allow full control?booleanisUnique(PermissionReference permissionReference) Does the permission reference have a unique name?
-
Method Details
-
getAllPermissions
Get the permissions that can be set for the given type.- Parameters:
type- - the type in the data dictionary.
-
getAllPermissions
Get the permissions that can be set for the given type.- Parameters:
type- - the type in the data dictionary.
-
getAllPermissions
Get the permissions that can be set for the given node. This is determined by the node type.- Parameters:
nodeRef- NodeRef
-
getExposedPermissions
Get the permissions that are exposed to be set for the given type.- Parameters:
type- - the type in the data dictionary.
-
getExposedPermissions
Get the permissions that are exposed to be set for the given node. This is determined by the node type.- Parameters:
nodeRef- NodeRef
-
getGrantingPermissions
Get all the permissions that grant this permission.- Parameters:
perm- PermissionReference
-
getRequiredPermissions
Set<PermissionReference> getRequiredPermissions(PermissionReference required, QName qName, Set<QName> aspectQNames, RequiredPermission.On on) Get the permissions that must also be present on the node for the required permission to apply.- Parameters:
required- PermissionReferenceqName- QNameon- RequiredPermission.On
-
getUnconditionalRequiredPermissions
Set<PermissionReference> getUnconditionalRequiredPermissions(PermissionReference required, RequiredPermission.On on) -
getGranteePermissions
Get the permissions which are granted by the supplied permission.- Parameters:
permissionReference- PermissionReference
-
getImmediateGranteePermissions
Get the permissions which are granted by the supplied permission.- Parameters:
permissionReference- PermissionReference
-
checkPermission
Is this permission refernece to a permission and not a permissoinSet?- Parameters:
required- PermissionReference- Returns:
- boolean
-
isUnique
Does the permission reference have a unique name?- Parameters:
permissionReference- PermissionReference- Returns:
- boolean
-
getPermissionReference
Find a permission by name in the type context. If the context is null and the permission name is unique it will be found.- Parameters:
qname- QNamepermissionName- String- Returns:
- PermissionReference
-
getGlobalPermissionEntries
Set<? extends PermissionEntry> getGlobalPermissionEntries()Get the global permissions for the model. Permissions that apply to all nodes and take precedence over node specific permissions.- Returns:
- Set
-
getAllExposedPermissions
Set<PermissionReference> getAllExposedPermissions()Get all exposed permissions (regardless of type exposure) -
getAllPermissions
Set<PermissionReference> getAllPermissions()Get all exposed permissions (regardless of type exposure) -
hasFull
Does this permission allow full control?- Parameters:
permissionReference- PermissionReference- Returns:
- boolean
-