Package org.activiti.api.task.runtime
Interface TaskAdminRuntime
public interface TaskAdminRuntime
All the methods require an authenticated Admin user
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddCandidateGroups(CandidateGroupsPayload candidateGroupsPayload) voidaddCandidateUsers(CandidateUsersPayload candidateUsersPayload) assign(AssignTaskPayload assignTaskPayload) Assign a task with a new user - If there is a user assigned, reassign it to the new user - after the assign the task should be in assigned statusassignMultiple(AssignTasksPayload assignTasksPayload) claim(ClaimTaskPayload claimTaskPayload) Claim a task with the currently authenticated user - If there is no authenticated user throw an IllegalStateException - If the currently authenticated user is not a candidate throw an IllegalStateException - The current approach doesn't support impersonation, it will always take the currently authenticated user - after the claim the task should be in assigned statuscomplete(CompleteTaskPayload completeTaskPayload) Completes the selected task with the variables set in the payload - This method checks that the task is visible by the authenticated user - This method also check that the task is assigned to the currently authenticated user before complete - This method return a shallow Task object with the basic information needed to validate that the task was completedvoidcreateVariable(CreateTaskVariablePayload createTaskVariablePayload) delete(DeleteTaskPayload deleteTaskPayload) Deletes a task - no matter the assignee or if the admin user can see the taskvoiddeleteCandidateGroups(CandidateGroupsPayload candidateGroupsPayload) voiddeleteCandidateUsers(CandidateUsersPayload candidateUsersPayload) groupCandidates(String taskId) lastCreatedTaskByProcessInstanceIdAndTaskDefinitionKey(String processInstanceId, String taskDefinitionKey) Finds the last created task by process instance id and task definition keyrelease(ReleaseTaskPayload releaseTaskPayload) Release a previously claimed task - The authenticated user needs to be the assignee in order to release itGet Task By IdGet all taskstasks(Pageable pageable, GetTasksPayload getTasksPayload) Get all tasks with payload filtersupdate(UpdateTaskPayload updateTaskPayload) Updates details of a taskvoidupdateVariable(UpdateTaskVariablePayload updateTaskVariablePayload) userCandidates(String taskId) variables(GetTaskVariablesPayload getTaskVariablesPayload)
-
Method Details
-
delete
Deletes a task - no matter the assignee or if the admin user can see the task -
task
Get Task By Id -
lastCreatedTaskByProcessInstanceIdAndTaskDefinitionKey
Task lastCreatedTaskByProcessInstanceIdAndTaskDefinitionKey(String processInstanceId, String taskDefinitionKey) Finds the last created task by process instance id and task definition key -
claim
Claim a task with the currently authenticated user - If there is no authenticated user throw an IllegalStateException - If the currently authenticated user is not a candidate throw an IllegalStateException - The current approach doesn't support impersonation, it will always take the currently authenticated user - after the claim the task should be in assigned status -
release
Release a previously claimed task - The authenticated user needs to be the assignee in order to release it -
complete
Completes the selected task with the variables set in the payload - This method checks that the task is visible by the authenticated user - This method also check that the task is assigned to the currently authenticated user before complete - This method return a shallow Task object with the basic information needed to validate that the task was completed -
update
Updates details of a task -
createVariable
-
updateVariable
-
variables
-
assign
Assign a task with a new user - If there is a user assigned, reassign it to the new user - after the assign the task should be in assigned status -
assignMultiple
-
addCandidateUsers
-
deleteCandidateUsers
-
addCandidateGroups
-
deleteCandidateGroups
-
userCandidates
-
groupCandidates
-