public interface TaskComponent
Modifier and Type | Method and Description |
---|---|
long |
countTasks(WorkflowTaskQuery query)
Count the number of active tasks that match the given query.
|
WorkflowTask |
endTask(String taskId,
String transitionId)
End the Task (i.e.
|
List<WorkflowTask> |
getAssignedTasks(String authority,
WorkflowTaskState state,
boolean lazyInitialization)
Gets all tasks assigned to the specified authority
|
List<WorkflowTask> |
getPooledTasks(List<String> authorities,
boolean lazyInitialization)
Gets the pooled tasks available to the specified authority
|
WorkflowTask |
getStartTask(String workflowInstanceId)
Gets all active timers for the specified workflow
|
List<WorkflowTask> |
getStartTasks(List<String> workflowInstanceIds,
boolean sameSession)
Gets all start tasks for the specified workflow
|
WorkflowTask |
getTaskById(String taskId)
Gets a Task by unique Id
|
List<WorkflowTask> |
queryTasks(WorkflowTaskQuery query)
Deprecated.
Use overloaded method with the
sameSession parameter
(this method defaults the parameter to false ). |
List<WorkflowTask> |
queryTasks(WorkflowTaskQuery query,
boolean sameSession)
Query for tasks
Hint: use
WorkflowTaskQuery setLimit() method to limit the number
of processed items if you don't really need to go through all of them |
WorkflowTask |
startTask(String taskId)
Start the specified Task
Note: this is an optional task operation.
|
WorkflowTask |
suspendTask(String taskId)
Suspend the specified Task
|
WorkflowTask |
updateTask(String taskId,
Map<org.alfresco.service.namespace.QName,Serializable> properties,
Map<org.alfresco.service.namespace.QName,List<org.alfresco.service.cmr.repository.NodeRef>> add,
Map<org.alfresco.service.namespace.QName,List<org.alfresco.service.cmr.repository.NodeRef>> remove)
Update the Properties and Associations of a Task
|
WorkflowTask getTaskById(String taskId)
taskId
- the task idList<WorkflowTask> getAssignedTasks(String authority, WorkflowTaskState state, boolean lazyInitialization)
authority
- the authoritystate
- filter by specified workflow task statelazyInitialization
- hint in order to return partially-initialized entitiesList<WorkflowTask> getPooledTasks(List<String> authorities, boolean lazyInitialization)
authorities
- the list of authoritieslazyInitialization
- hint in order to return partially-initialized entitiesList<WorkflowTask> queryTasks(WorkflowTaskQuery query)
sameSession
parameter
(this method defaults the parameter to false
).List<WorkflowTask> queryTasks(WorkflowTaskQuery query, boolean sameSession)
WorkflowTaskQuery
setLimit() method to limit the number
of processed items if you don't really need to go through all of themquery
- the filter by which tasks are queriedsameSession
- indicates that the returned WorkflowTask
elements will
be used in the same session. If true
, the returned
List will be a lazy loaded list providing greater performance.long countTasks(WorkflowTaskQuery query)
query
- the filter by which tasks are queriedWorkflowTask updateTask(String taskId, Map<org.alfresco.service.namespace.QName,Serializable> properties, Map<org.alfresco.service.namespace.QName,List<org.alfresco.service.cmr.repository.NodeRef>> add, Map<org.alfresco.service.namespace.QName,List<org.alfresco.service.cmr.repository.NodeRef>> remove)
taskId
- the task id to updateproperties
- the map of properties to set on the task (or null, if none to set)add
- the map of items to associate with the task (or null, if none to add)remove
- the map of items to dis-associate with the task (or null, if none to remove)WorkflowTask startTask(String taskId)
taskId
- the task to startWorkflowTask suspendTask(String taskId)
taskId
- StringWorkflowTask endTask(String taskId, String transitionId)
taskId
- the task id to endtransitionId
- the task transition id to take on completion (or null, for the default transition)WorkflowTask getStartTask(String workflowInstanceId)
List<WorkflowTask> getStartTasks(List<String> workflowInstanceIds, boolean sameSession)
Copyright © 2005–2017 Alfresco Software. All rights reserved.