Package org.alfresco.repo.template
Class BasePermissionsNode
- java.lang.Object
-
- org.alfresco.repo.template.BaseContentNode
-
- org.alfresco.repo.template.BasePermissionsNode
-
- All Implemented Interfaces:
java.io.Serializable,TemplateContent,TemplateNodeRef,TemplatePermissions,TemplateProperties
- Direct Known Subclasses:
TemplateNode
public abstract class BasePermissionsNode extends BaseContentNode implements TemplatePermissions
Base class for Template API objects that support permissions.- Author:
- Kevin Roast
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.alfresco.repo.template.BaseContentNode
BaseContentNode.TemplateContentData
-
-
Field Summary
-
Fields inherited from class org.alfresco.repo.template.BaseContentNode
aspects, children, CONTENT_DOWNLOAD_PROP_URL, CONTENT_DOWNLOAD_URL, CONTENT_GET_PROP_URL, CONTENT_GET_URL, CONTENT_SERVICE_GET_PROP_URL, CONTENT_SERVICE_GET_URL, FOLDER_BROWSE_URL, imageResolver, NAMESPACE_BEGIN, services
-
-
Constructor Summary
Constructors Constructor Description BasePermissionsNode()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.lang.String>getDirectPermissions()java.util.List<java.lang.String>getFullPermissions()booleangetInheritsPermissions()java.util.List<java.lang.String>getPermissions()booleanhasPermission(java.lang.String permission)-
Methods inherited from class org.alfresco.repo.template.BaseContentNode
getAspects, getChildren, getContent, getDisplayMimetype, getDisplayPath, getDownloadUrl, getEncoding, getHasChildren, getIcon16, getIcon32, getIcon64, getIsContainer, getIsDocument, getIsLinkToContainer, getIsLinkToDocument, getMimetype, getQnamePath, getServiceUrl, getSiteShortName, getSize, getUrl, getWebdavUrl, hasAspect, isTemplateContent, isTemplateNodeRef, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.alfresco.repo.template.TemplateNodeRef
getId, getName, getNodeRef, getType
-
Methods inherited from interface org.alfresco.repo.template.TemplateProperties
getParent, getProperties
-
-
-
-
Method Detail
-
getPermissions
public java.util.List<java.lang.String> getPermissions()
- Specified by:
getPermissionsin interfaceTemplatePermissions- Returns:
- List of permissions applied to this Node, including inherited. Strings returned are of the format [ALLOWED|DENIED];[USERNAME|GROUPNAME];PERMISSION for example ALLOWED;kevinr;Consumer so can be easily tokenized on the ';' character.
-
getDirectPermissions
public java.util.List<java.lang.String> getDirectPermissions()
- Returns:
- List of permissions applied to this Node (does not include inherited). Strings returned are of the format [ALLOWED|DENIED];[USERNAME|GROUPNAME];PERMISSION for example ALLOWED;kevinr;Consumer so can be easily tokenized on the ';' character.
-
getFullPermissions
public java.util.List<java.lang.String> getFullPermissions()
- Returns:
- List of permissions applied to this Node, including inherited. Strings returned are of the format [ALLOWED|DENIED];[USERNAME|GROUPNAME];PERMISSION;[INHERITED|DIRECT] for example ALLOWED;kevinr;Consumer so can be easily tokenized on the ';' character.
-
getInheritsPermissions
public boolean getInheritsPermissions()
- Specified by:
getInheritsPermissionsin interfaceTemplatePermissions- Returns:
- true if this node inherits permissions from its parent node, false otherwise.
-
hasPermission
public boolean hasPermission(java.lang.String permission)
- Specified by:
hasPermissionin interfaceTemplatePermissions- Parameters:
permission- Permission name to test- Returns:
- true if the current user is granted the specified permission on the node
-
-