Package com.appiancorp.suiteapi.content
Class ContentRoleMap
java.lang.Object
com.appiancorp.suiteapi.common.RoleMap
com.appiancorp.suiteapi.content.ContentRoleMap
- All Implemented Interfaces:
XMLable
,Serializable
,Map
This class represents the access permissions for an element in the collaboration center.
Copyright: Copyright (c) 2002, 2003
Company: Appian Corporation
- See Also:
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Role with administrative access.static final String[]
static final String
Role with read/write access.static final String
Explicitly deny administrative access.static final String
Explicitly deny read/write access.static final String
Explicitly deny read-only access.static final String
Role with read-only access.Fields inherited from class com.appiancorp.suiteapi.common.RoleMap
AGGREGATE_SECURITY_KEY, SECURITY_KEY, TYPE_AGGREGATE_GROUP, TYPE_AGGREGATE_USER, TYPE_GROUP, TYPE_GROUP_UUIDS, TYPE_USER, TYPE_USER_UUIDS
Fields inherited from interface com.appiancorp.suiteapi.common.XMLable
DEFAULT_BUFFER_SIZE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addAdministratorGroups
(Long... grids_) Appends to the groups who have administrative permissions.void
addAdministrators
(String... unames_) Appends to the users who have administrative permissions.void
addAuthorGroups
(Long... grids_) Appends to the groups who have authoring (read/write) permissions.void
addAuthors
(String... unames_) Appends to the users who have authoring (read/write) permissions.void
addDenyAdministratorGroups
(Long... grids_) Appends to the groups who have been explicitly denied administrative permissions.void
addDenyAdministrators
(String... unames_) Appends to the users who have been explicitly denied administrative permissions.void
addDenyAuthorGroups
(Long... grids_) Appends to the groups who have been explicitly denied authoring (read/write) permissions.void
addDenyAuthors
(String... unames_) Appends to the users who have been explicitly denied authoring (read/write) permissions.void
addDenyReaderGroups
(Long... grids_) Appends to the groups who have been explicitly denied read-only permissions.void
addDenyReaders
(String... unames_) Appends to the users who have been explicitly denied read-only permissions.void
addReaderGroups
(Long... grids_) Appends to the groups who have read-only permissions.void
addReaders
(String... unames_) Appends to the users who have read-only permissions.Long[]
Retrieves the groups who have administrative permissions.String[]
Retrieves the users who have administrative permissions.Long[]
Retrieves the groups who have administrative permissions aggregated via the chain of parent object.String[]
Retrieves the users who have administrative permissions aggregated via the chain of parent objects.Long[]
Retrieves the groups who have authoring permissions aggregated via the chain of parent objects.String[]
Retrieves the users who have authoring permissions aggregated via the chain of parent objects.Long[]
Retrieves the groups who have been explicitly denied administrative permissions aggregated via the chain of parent objects.String[]
Retrieves the users who have been explicitly denied administrative permissions aggregated via the chain of parent objects.Long[]
Retrieves the groups who have been explicitly denied authoring permissions aggregated via the chain of parent objects.String[]
Retrieves the users who have been explicitly denied authoring permissions aggregated via the chain of parent objects.Long[]
Retrieves the groups who have been explicitly denied read-only permissions aggregated via the chain of parent objects.String[]
Retrieves the users who have been explicitly denied read-only permissions aggregated via the chain of parent objects.Long[]
Retrieves the groups who have read-only permissions aggregated via the chain of parent objects.String[]
Retrieves the users who have read-only permissions aggregated via the chain of parent objects.Long[]
Retrieves the groups who have authoring (read/write) permissions.String[]
Retrieves the users who have authoring (read/write) permissions.Long[]
Retrieves the groups who have been explicitly denied administrative permissions.String[]
Retrieves the users who have been explicitly denied administrative permissions.Long[]
Retrieves the groups who have authoring (read/write) permissions.String[]
Retrieves the users who have authoring (read/write) permissions.Long[]
Retrieves the groups who have been explicitly denied read-only permissions.String[]
Retrieves the users who have been explicitly denied read-only permissions.Long[]
Retrieves the groups who have read-only permissions.String[]
Retrieves the users who have read-only permissions.protected ContentRole
getRoles()
Returns an array of ContentRole objects for every Content role (seeContentConstants.ROLE_MAP_ROLES
).boolean
isPublic()
Indicates that the content is public.void
Merges this role map with the given new role map.void
removeAdministratorGroups
(Long... grids_) Deletes from the groups who have administrative permissions.void
removeAdministrators
(String... unames_) Deletes from the users who have administrative permissions.protected void
void
removeAuthorGroups
(Long... grids_) Delete from the groups who have authoring (read/write) permissions.void
removeAuthors
(String... unames_) Delete from the users who have authoring (read/write) permissions.void
removeDenyAdministratorGroups
(Long... grids_) Deletes from the groups who have been explicitly denied administrative permissions.void
removeDenyAdministrators
(String... unames_) Deletes from the users who have been explicitly denied administrative permissions.void
removeDenyAuthorGroups
(Long... grids_) Delete from the groups who have been explicitly denied authoring (read/write) permissions.void
removeDenyAuthors
(String... unames_) Delete from the users who have been explicitly denied authoring (read/write) permissions.void
removeDenyReaderGroups
(Long... grids_) Delete from the groups who have been explicitly denied read-only permissions.void
removeDenyReaders
(String... unames_) Delete from the users who have been explicitly denied read-only permissions.void
removeReaderGroups
(Long... grids_) Delete from the groups who have read-only permissions.void
removeReaders
(String... unames_) Delete from the users who have read-only permissions.void
setAdministratorGroups
(Long... grids_) Sets the groups who have administrative permissions.void
setAdministrators
(String... unames_) Sets the users who have administrative permissions.void
setAuthorGroups
(Long... grids_) Sets the groups who have authoring (read/write) permissions.void
setAuthors
(String... unames_) Sets the users who have authoring (read/write) permissions.void
setDenyAdministratorGroups
(Long... grids_) Sets the groups who have been explicitly denied administrative permissions.void
setDenyAdministrators
(String... unames_) Sets the users who have been explicitly denied administrative permissions.void
setDenyAuthorGroups
(Long... grids_) Sets the groups who have been explicitly denied authoring (read/write) permissions.void
setDenyAuthors
(String... unames_) Sets the users who have been explicitly denied authoring (read/write) permissions.void
setDenyReaderGroups
(Long... grids_) Sets the groups who have been explicitly denied authoring read-only permissions.void
setDenyReaders
(String... unames_) Sets the users who have been explicitly denied read-only permissions.void
setPublic
(boolean secPublic) void
setReaderGroups
(Long... grids_) Sets the groups who have authoring read-only permissions.void
setReaders
(String... unames_) Sets the users who have read-only permissions.protected void
void
Removes any roles that are currently set and sets the roles to the given data.void
setRoles
(Collection<? extends Role> roles) Removes any roles that are currently set and sets the roles to the given data.toString()
static String
toStringSecurityVector
(Integer contentSecurityVector) Methods inherited from class com.appiancorp.suiteapi.common.RoleMap
addActorsToRole, addActorsToRole, clear, containsActors, containsKey, containsValue, entrySet, equals, get, getActorsInRole, getAggregateSecurity, getAllGroupIds, getAllUsernames, getRoleNames, getSecurity, hashCode, init, isEmpty, keySet, put, putAll, remove, removeActorsFromRole, removeActorsFromRole, setActorsInRole, setActorsInRole, setAggregateSecurity, setSecurity, size, toXML, toXML, values
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Field Details
-
READER
Role with read-only access.- See Also:
-
AUTHOR
Role with read/write access.- See Also:
-
ADMINISTRATOR
Role with administrative access.- See Also:
-
DENY_READER
Explicitly deny read-only access.- See Also:
-
DENY_AUTHOR
Explicitly deny read/write access.- See Also:
-
DENY_ADMINISTRATOR
Explicitly deny administrative access.- See Also:
-
ALL_ROLES
-
-
Constructor Details
-
ContentRoleMap
public ContentRoleMap()
-
-
Method Details
-
getAdministrators
Retrieves the users who have administrative permissions.- Returns:
- a list containing the unique IDs of the users
- See Also:
-
getAggregateAdministrators
Retrieves the users who have administrative permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the users
-
getAdministratorGroups
Retrieves the groups who have administrative permissions.- Returns:
- a list containing the unique IDs of the groups
- See Also:
-
getAggregateAdministratorGroups
Retrieves the groups who have administrative permissions aggregated via the chain of parent object.- Returns:
- a list containing the unique IDs of the groups
-
setAdministrators
Sets the users who have administrative permissions.- Parameters:
unames_
- a list containing the unique IDs of the users- See Also:
-
setAdministratorGroups
Sets the groups who have administrative permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups- See Also:
-
addAdministrators
Appends to the users who have administrative permissions.- Parameters:
unames_
- a list containing the unique IDs of the users to be added
-
addAdministratorGroups
Appends to the groups who have administrative permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups to be added
-
removeAdministrators
Deletes from the users who have administrative permissions.- Parameters:
unames_
- a list containing the unique IDs of the users to be deleted
-
removeAdministratorGroups
Deletes from the groups who have administrative permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups to be deleted
-
getAuthors
Retrieves the users who have authoring (read/write) permissions.- Returns:
- a list containing the unique IDs of the users who have authoring (read/write) permissions
- See Also:
-
getAggregateAuthors
Retrieves the users who have authoring permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the users
-
getAuthorGroups
Retrieves the groups who have authoring (read/write) permissions.- Returns:
- a list containing the unique IDs of the groups
- See Also:
-
getAggregateAuthorGroups
Retrieves the groups who have authoring permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the groups
-
getReaders
Retrieves the users who have read-only permissions.- Returns:
- a list containing the unique IDs of the users who have read-only permissions
- See Also:
-
getAggregateReaders
Retrieves the users who have read-only permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the users who have read-only permissions
-
getReaderGroups
Retrieves the groups who have read-only permissions.- Returns:
- a list containing the unique IDs the groups who have read-only permissions
- See Also:
-
getAggregateReaderGroups
Retrieves the groups who have read-only permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs the groups who have read-only permissions
-
setAuthors
Sets the users who have authoring (read/write) permissions.- Parameters:
unames_
- a list containing the unique IDs of the users- See Also:
-
setAuthorGroups
Sets the groups who have authoring (read/write) permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups- See Also:
-
setReaders
Sets the users who have read-only permissions.- Parameters:
unames_
- a list containing the unique IDs of the users- See Also:
-
setReaderGroups
Sets the groups who have authoring read-only permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups- See Also:
-
addAuthors
Appends to the users who have authoring (read/write) permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
addAuthorGroups
Appends to the groups who have authoring (read/write) permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
addReaders
Appends to the users who have read-only permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
addReaderGroups
Appends to the groups who have read-only permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
removeAuthors
Delete from the users who have authoring (read/write) permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
removeAuthorGroups
Delete from the groups who have authoring (read/write) permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
removeReaders
Delete from the users who have read-only permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
removeReaderGroups
Delete from the groups who have read-only permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
getDenyAdministrators
Retrieves the users who have been explicitly denied administrative permissions.- Returns:
- a list containing the unique IDs of the users
- See Also:
-
getAggregateDenyAdministrators
Retrieves the users who have been explicitly denied administrative permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the users
-
getDenyAdministratorGroups
Retrieves the groups who have been explicitly denied administrative permissions.- Returns:
- a list containing the unique IDs of the groups
- See Also:
-
getAggregateDenyAdministratorGroups
Retrieves the groups who have been explicitly denied administrative permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the groups
-
setDenyAdministrators
Sets the users who have been explicitly denied administrative permissions.- Parameters:
unames_
- a list containing the unique IDs of the users- See Also:
-
setDenyAdministratorGroups
Sets the groups who have been explicitly denied administrative permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups- See Also:
-
addDenyAdministrators
Appends to the users who have been explicitly denied administrative permissions.- Parameters:
unames_
- a list containing the unique IDs of the users to be added
-
addDenyAdministratorGroups
Appends to the groups who have been explicitly denied administrative permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups to be added
-
removeDenyAdministrators
Deletes from the users who have been explicitly denied administrative permissions.- Parameters:
unames_
- a list containing the unique IDs of the users to be deleted
-
removeDenyAdministratorGroups
Deletes from the groups who have been explicitly denied administrative permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups to be deleted
-
getDenyAuthors
Retrieves the users who have authoring (read/write) permissions.- Returns:
- a list containing the unique IDs of the users who have authoring (read/write) permissions.
- See Also:
-
getAggregateDenyAuthors
Retrieves the users who have been explicitly denied authoring permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the users who have authoring (read/write) permissions
-
getDenyAuthorGroups
Retrieves the groups who have authoring (read/write) permissions.- Returns:
- a list containing the unique IDs of the groups who have authoring (read/write) permissions
- See Also:
-
getAggregateDenyAuthorGroups
Retrieves the groups who have been explicitly denied authoring permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the groups who have authoring (read/write) permissions
-
getDenyReaders
Retrieves the users who have been explicitly denied read-only permissions.- Returns:
- a list containing the unique IDs of the users who have read-only permissions
- See Also:
-
getAggregateDenyReaders
Retrieves the users who have been explicitly denied read-only permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs of the users who have read-only permissions
-
getDenyReaderGroups
Retrieves the groups who have been explicitly denied read-only permissions.- Returns:
- a list containing the unique IDs the groups who have read-only permissions
- See Also:
-
getAggregateDenyReaderGroups
Retrieves the groups who have been explicitly denied read-only permissions aggregated via the chain of parent objects.- Returns:
- a list containing the unique IDs the groups who have read-only permissions
-
setDenyAuthors
Sets the users who have been explicitly denied authoring (read/write) permissions.- Parameters:
unames_
- a list containing the unique IDs of the users- See Also:
-
setDenyAuthorGroups
Sets the groups who have been explicitly denied authoring (read/write) permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups- See Also:
-
setDenyReaders
Sets the users who have been explicitly denied read-only permissions.- Parameters:
unames_
- a list containing the unique IDs of the users- See Also:
-
setDenyReaderGroups
Sets the groups who have been explicitly denied authoring read-only permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups- See Also:
-
addDenyAuthors
Appends to the users who have been explicitly denied authoring (read/write) permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
addDenyAuthorGroups
Appends to the groups who have been explicitly denied authoring (read/write) permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
addDenyReaders
Appends to the users who have been explicitly denied read-only permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
addDenyReaderGroups
Appends to the groups who have been explicitly denied read-only permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
removeDenyAuthors
Delete from the users who have been explicitly denied authoring (read/write) permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
removeDenyAuthorGroups
Delete from the groups who have been explicitly denied authoring (read/write) permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
removeDenyReaders
Delete from the users who have been explicitly denied read-only permissions.- Parameters:
unames_
- a list containing the unique IDs of the users
-
removeDenyReaderGroups
Delete from the groups who have been explicitly denied read-only permissions.- Parameters:
grids_
- a list containing the unique IDs of the groups
-
isPublic
public boolean isPublic()Indicates that the content is public. The difference between public and non-public content is the editor role; for non-public, someone with just editor (not edit) before they can create, delete, or update content. -
setPublic
public void setPublic(boolean secPublic) - See Also:
-
getRoles
Returns an array of ContentRole objects for every Content role (seeContentConstants.ROLE_MAP_ROLES
). -
setRoles
Removes any roles that are currently set and sets the roles to the given data. If the given array is null or empty the existing roles are cleared. -
setRoles
Removes any roles that are currently set and sets the roles to the given data. If the given array is null or empty the existing roles are cleared. -
removeAllRoles
protected void removeAllRoles()- Overrides:
removeAllRoles
in classRoleMap
-
getRole
-
setRole
-
mergeWith
Description copied from class:RoleMap
Merges this role map with the given new role map. Only the fieldsRoleMap.TYPE_USER
andRoleMap.TYPE_GROUP
are merged. All other fields are left unchanged. The following rules are used to merge the users and groups:- The merged role map should be the union of the existing and new role maps.
- When the same user/group is present in both the existing and new role maps, the role from the NEW role map should be used for the user/group.
-
toString
-
toStringSecurityVector
-