Modifier and Type | Method and Description |
---|---|
BatchOperation<Void,BatchOperationError> |
batchAssignMissingUsers(List<DocumentVersion> documentVersions,
String roleName,
List<String> userIds)
Creates an operation which can be used to update document roles such that all of the given user Ids are on the
given document lifecycle role on all of the given documents.
|
BatchOperation<Void,BatchOperationError> |
batchUpdateDocumentRoles(List<DocumentRoleUpdate> documentRoleUpdates)
Creates an operation which can be used to update document roles.
|
GetDocumentRolesResponse |
getDocumentRoles(List<DocumentVersion> documentVersions,
String roleName)
Retrieves a
GetDocumentRolesResponse for the given list of document versions which can be used to get
DocumentRole for a particular document. |
GetGroupInDocumentRolesResponse |
getGroupInDocumentRoles(Group group,
List<DocumentRole> documentRoles)
For the given group, returns a
GetGroupInDocumentRolesResponse which can be used to check if the group is
in a particular document role. |
GetMissingAssignmentsDocumentResponse |
getMissingAssignments(List<DocumentVersion> documentVersions,
String roleName,
List<String> userIds)
Retrieves a
GetMissingAssignmentsDocumentResponse which can be used to check for an incompleteness of
document roles. |
GetUserInDocumentRolesResponse |
getUserInDocumentRoles(String userId,
List<DocumentRole> documentRoles)
For a given userId, returns a
GetUserInDocumentRolesResponse which can be used to check if the user is in
a particular document role. |
DocumentRoleUpdate |
newDocumentRoleUpdate(String roleName,
DocumentVersion documentVersion)
Creates a
DocumentRoleUpdate which can be submitted to batchUpdateDocumentRoles(List) to update
document roles on a particular document. |
GetDocumentRolesResponse getDocumentRoles(List<DocumentVersion> documentVersions, String roleName)
GetDocumentRolesResponse
for the given list of document versions which can be used to get
DocumentRole
for a particular document.
The given roleName must be a valid option on each included DocumentVersion
.
documentVersions
- List of document versions. Cannot exceed 500 documents.roleName
- Name of a document lifecycle role.GetDocumentRolesResponse
for more information.GetUserInDocumentRolesResponse getUserInDocumentRoles(String userId, List<DocumentRole> documentRoles)
GetUserInDocumentRolesResponse
which can be used to check if the user is in
a particular document role.
While a GetDocumentRolesResponse
only contains direct manual assignments, this method will allow you to
check if a user is in a document role from manual or automated assignments. In addition, this method will
check if the user is in a document role indirectly through a group.
userId
- The ID for a user. Cannot be null.documentRoles
- List of document roles. Cannot be null or exceed 500 documentRoles.GetUserInDocumentRolesResponse
for more information.GetGroupInDocumentRolesResponse getGroupInDocumentRoles(Group group, List<DocumentRole> documentRoles)
GetGroupInDocumentRolesResponse
which can be used to check if the group is
in a particular document role.
While a GetDocumentRolesResponse
only contains direct manual assignments, this method will allow you to
check if a group is in a document role from manual or automated assignments.
group
- A group object. Cannot be null.documentRoles
- List of document roles. Cannot be null or exceed 500 documentRoles.GetGroupInDocumentRolesResponse
for more information.DocumentRoleUpdate newDocumentRoleUpdate(String roleName, DocumentVersion documentVersion)
DocumentRoleUpdate
which can be submitted to batchUpdateDocumentRoles(List)
to update
document roles on a particular document.roleName
- Name of a document lifecycle role.documentVersion
- A document for which roles will be updated.DocumentRoleUpdate
for more information.BatchOperation<Void,BatchOperationError> batchUpdateDocumentRoles(List<DocumentRoleUpdate> documentRoleUpdates)
The way that errors are handled can be specified on the returned BatchOperation
. Once error-handling has
been specified, the method BatchOperation.execute()
must be called to finally execute the update.
For example:
documentRoleService.batchUpdateDocumentRoles(documentRoleUpdates).rollbackOnErrors().execute()
documentRoleUpdates
- A list of updates to be made. Cannot be null or exceed 500 documentRoleUpdates.GetMissingAssignmentsDocumentResponse getMissingAssignments(List<DocumentVersion> documentVersions, String roleName, List<String> userIds)
GetMissingAssignmentsDocumentResponse
which can be used to check for an incompleteness of
document roles.
The given roleName must be a valid option on each included DocumentVersion
.
documentVersions
- A list of document versions. Cannot be null or exceed 500 documents.roleName
- Name of a document lifecycle role.userIds
- A list of user Ids. Cannot be null or exceed 500 ids.BatchOperation<Void,BatchOperationError> batchAssignMissingUsers(List<DocumentVersion> documentVersions, String roleName, List<String> userIds)
The given roleName must be a valid option on each included DocumentVersion
.
The way that errors are handled can be specified on the returned BatchOperation
. Once error-handling has
been specified, the method BatchOperation.execute()
must be called to finally execute the update.
For example:
documentRoleService.batchUpdateDocumentRoles(documentRoleUpdates).rollbackOnErrors().execute()
documentVersions
- A list of document versions. Cannot be null or exceed 500 documents.roleName
- Name of a document lifecycle role.userIds
- A list of user Ids. Cannot be null or exceed 500 ids.Copyright © Veeva Systems 2017–2018. All rights reserved.