Package org.jbpm.kie.services.impl
Class UserTaskServiceImpl
- java.lang.Object
-
- org.jbpm.kie.services.impl.UserTaskServiceImpl
-
- All Implemented Interfaces:
VariablesAware
,UserTaskService
- Direct Known Subclasses:
UserTaskServiceCDIImpl
,UserTaskServiceEJBImpl
public class UserTaskServiceImpl extends Object implements UserTaskService, VariablesAware
-
-
Constructor Summary
Constructors Constructor Description UserTaskServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
activate(Long taskId, String userId)
Activate the task, i.e. set the task to status Ready.void
activate(String deploymentId, Long taskId, String userId)
Activate the task, i.e. set the task to status Ready.Long
addAttachment(Long taskId, String userId, String name, Object attachment)
Add attachment to a taskLong
addAttachment(String deploymentId, Long taskId, String userId, String name, Object attachment)
Add attachment to a taskLong
addComment(Long taskId, String text, String addedBy, Date addedOn)
Add comment to a taskLong
addComment(String deploymentId, Long taskId, String text, String addedBy, Date addedOn)
Add comment to a taskvoid
claim(Long taskId, String userId)
Claim responsibility for a task, i.e. set the task to status Reservedvoid
claim(String deploymentId, Long taskId, String userId)
Claim responsibility for a task, i.e. set the task to status Reservedvoid
claim(String deploymentId, Collection<Long> taskIds, String userId)
Claim responsibility for a list of tasks, i.e. set the tasks to status Reservedvoid
complete(Long taskId, String userId, Map<String,Object> params)
Complete a task with the given datavoid
complete(String deploymentId, Long taskId, String userId, Map<String,Object> params)
Complete a task with the given datavoid
completeAutoProgress(Long taskId, String userId, Map<String,Object> params)
Complete a task with the given data.void
completeAutoProgress(String deploymentId, Long taskId, String userId, Map<String,Object> params)
Complete a task with the given data.void
delegate(Long taskId, String userId, String targetUserId)
Delegate a task from userId to targetUserIdvoid
delegate(String deploymentId, Long taskId, String userId, String targetUserId)
Delegate a task from userId to targetUserIdvoid
deleteAttachment(Long taskId, Long attachmentId)
Delete attachment from a taskvoid
deleteAttachment(String deploymentId, Long taskId, Long attachmentId)
Delete attachment from a taskvoid
deleteComment(Long taskId, Long commentId)
Deletes comment from a taskvoid
deleteComment(String deploymentId, Long taskId, Long commentId)
Deletes comment from a taskvoid
deleteContent(Long taskId, Long contentId)
Deletes content given bycontentId
from given taskvoid
deleteContent(String deploymentId, Long taskId, Long contentId)
Deletes content given bycontentId
from given taskprotected void
disposeRuntimeEngine(org.kie.api.runtime.manager.RuntimeManager manager, org.kie.api.runtime.manager.RuntimeEngine engine)
<T> T
execute(String deploymentId, org.kie.api.command.Command<T> command)
Executes provided command on the underlying command executor<T> T
execute(String deploymentId, org.kie.api.runtime.manager.Context<?> context, org.kie.api.command.Command<T> command)
Executes provided command on the underlying command executorvoid
exit(Long taskId, String userId)
Requesting application is no longer interested in the task outputvoid
exit(String deploymentId, Long taskId, String userId)
Requesting application is no longer interested in the task outputvoid
fail(Long taskId, String userId, Map<String,Object> faultData)
Actual owner completes the execution of the task raising a fault.void
fail(String deploymentId, Long taskId, String userId, Map<String,Object> faultData)
Actual owner completes the execution of the task raising a fault.void
forward(Long taskId, String userId, String targetEntityId)
Forward the task to another organization entity.void
forward(String deploymentId, Long taskId, String userId, String targetEntityId)
Forward the task to another organization entity.org.kie.api.task.model.Attachment
getAttachmentById(Long taskId, Long attachmentId)
Get attachment by identifierorg.kie.api.task.model.Attachment
getAttachmentById(String deploymentId, Long taskId, Long attachmentId)
Get attachment by identifierObject
getAttachmentContentById(Long taskId, Long attachmentId)
Get attachment's content by identifierObject
getAttachmentContentById(String deploymentId, Long taskId, Long attachmentId)
Get attachment's content by identifierList<org.kie.api.task.model.Attachment>
getAttachmentsByTaskId(Long taskId)
Get attachments for a taskList<org.kie.api.task.model.Attachment>
getAttachmentsByTaskId(String deploymentId, Long taskId)
Get attachments for a taskorg.kie.api.task.model.Comment
getCommentById(Long taskId, Long commentId)
Get comment by identifierorg.kie.api.task.model.Comment
getCommentById(String deploymentId, Long taskId, Long commentId)
Get comment by identifierList<org.kie.api.task.model.Comment>
getCommentsByTaskId(Long taskId)
Get comments for a taskList<org.kie.api.task.model.Comment>
getCommentsByTaskId(String deploymentId, Long taskId)
Get comments for a taskprotected org.kie.internal.task.api.InternalTaskService
getInternalTaskService()
protected org.kie.api.runtime.manager.RuntimeManager
getRuntimeManager(String deploymentId, org.kie.api.command.Command<?> command)
protected org.kie.api.runtime.manager.RuntimeManager
getRuntimeManager(UserTaskInstanceDesc task)
org.kie.api.task.model.Task
getTask(Long taskId)
Returns task instanceorg.kie.api.task.model.Task
getTask(String deploymentId, Long taskId)
Returns task instanceMap<String,Object>
getTaskInputContentByTaskId(Long taskId)
Returns task input data of a taskMap<String,Object>
getTaskInputContentByTaskId(String deploymentId, Long taskId)
Returns task input data of a taskMap<String,Object>
getTaskOutputContentByTaskId(Long taskId)
Returns task output data currently stored, might be null of no data is storedMap<String,Object>
getTaskOutputContentByTaskId(String deploymentId, Long taskId)
Returns task output data currently stored, might be null of no data is storedvoid
nominate(Long taskId, String userId, List<org.kie.api.task.model.OrganizationalEntity> potentialOwners)
Nominate a task to be handled by potentialOwnersvoid
nominate(String deploymentId, Long taskId, String userId, List<org.kie.api.task.model.OrganizationalEntity> potentialOwners)
Nominate a task to be handled by potentialOwners<T> T
process(T variables, ClassLoader cl)
Generic processing method that might be simply returning same instance of variables if no processing is required.void
release(Long taskId, String userId)
Release a previously claimed taskvoid
release(String deploymentId, Long taskId, String userId)
Release a previously claimed taskvoid
resume(Long taskId, String userId)
Resume a previously suspended taskvoid
resume(String deploymentId, Long taskId, String userId)
Resume a previously suspended taskLong
saveContent(Long taskId, Map<String,Object> values)
Saves gives values as content of a task, applies to task output as input cannot be alteredLong
saveContent(String deploymentId, Long taskId, String userId, Map<String,Object> values)
Long
saveContent(String deploymentId, Long taskId, Map<String,Object> values)
Saves gives values as content of a task, applies to task output as input cannot be alteredLong
saveContentFromUser(Long taskId, String userId, Map<String,Object> values)
Saves gives values as content of a task, applies to task output as input cannot be alteredvoid
setDataService(RuntimeDataService dataService)
void
setDeploymentService(DeploymentService deploymentService)
void
setDescription(Long taskId, String description)
Sets description of the taskvoid
setDescription(String deploymentId, Long taskId, String description)
Sets description of the taskvoid
setExpirationDate(Long taskId, Date date)
Sets expiration date of a task to given valuevoid
setExpirationDate(String deploymentId, Long taskId, Date date)
Sets expiration date of a task to given valuevoid
setName(Long taskId, String name)
Sets name of the taskvoid
setName(String deploymentId, Long taskId, String name)
Sets name of the taskvoid
setNonProcessScopedTaskService(org.kie.internal.task.api.InternalTaskService nonProcessScopedTaskService)
void
setPriority(Long taskId, int priority)
Sets priority of a task to given valuevoid
setPriority(String deploymentId, Long taskId, int priority)
Sets priority of a task to given valuevoid
setSkipable(Long taskId, boolean skipable)
Sets skipable property of a task to given valuevoid
setSkipable(String deploymentId, Long taskId, boolean skipable)
Sets skipable property of a task to given valuevoid
skip(Long taskId, String userId)
Skip a claimed taskvoid
skip(String deploymentId, Long taskId, String userId)
Skip a claimed taskvoid
start(Long taskId, String userId)
Start the execution of the task, i.e. set the task to status InProgress.void
start(String deploymentId, Long taskId, String userId)
Start the execution of the task, i.e. set the task to status InProgress.void
stop(Long taskId, String userId)
Cancel/stop the processing of the task.void
stop(String deploymentId, Long taskId, String userId)
Cancel/stop the processing of the task.void
suspend(Long taskId, String userId)
Suspend a claimed task.void
suspend(Long taskId, String userId, Map<String,Object> parameters)
Suspend a claimed task with given parametersvoid
suspend(String deploymentId, Long taskId, String userId)
Suspend a claimed task.void
suspend(String deploymentId, Long taskId, String userId, Map<String,Object> parameters)
Suspend a claimed task.void
updateTask(Long taskId, String userId, UserTaskInstanceDesc userTask, Map<String,Object> inputData, Map<String,Object> outputData)
Updates user task properties and data inputs and outputs.void
updateTask(String deploymentId, Long taskId, String userId, UserTaskInstanceDesc userTask, Map<String,Object> inputData, Map<String,Object> outputData)
Updates user task properties and data inputs and outputs.protected void
validateTask(String deploymentId, Long taskId, UserTaskInstanceDesc task)
-
-
-
Method Detail
-
setDeploymentService
public void setDeploymentService(DeploymentService deploymentService)
-
setDataService
public void setDataService(RuntimeDataService dataService)
-
setNonProcessScopedTaskService
public void setNonProcessScopedTaskService(org.kie.internal.task.api.InternalTaskService nonProcessScopedTaskService)
-
getInternalTaskService
protected org.kie.internal.task.api.InternalTaskService getInternalTaskService()
-
getRuntimeManager
protected org.kie.api.runtime.manager.RuntimeManager getRuntimeManager(UserTaskInstanceDesc task)
-
getRuntimeManager
protected org.kie.api.runtime.manager.RuntimeManager getRuntimeManager(String deploymentId, org.kie.api.command.Command<?> command)
-
validateTask
protected void validateTask(String deploymentId, Long taskId, UserTaskInstanceDesc task)
-
activate
public void activate(Long taskId, String userId)
Description copied from interface:UserTaskService
Activate the task, i.e. set the task to status Ready.- Specified by:
activate
in interfaceUserTaskService
-
activate
public void activate(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Activate the task, i.e. set the task to status Ready.- Specified by:
activate
in interfaceUserTaskService
-
claim
public void claim(Long taskId, String userId)
Description copied from interface:UserTaskService
Claim responsibility for a task, i.e. set the task to status Reserved- Specified by:
claim
in interfaceUserTaskService
-
claim
public void claim(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Claim responsibility for a task, i.e. set the task to status Reserved- Specified by:
claim
in interfaceUserTaskService
-
claim
public void claim(String deploymentId, Collection<Long> taskIds, String userId)
Description copied from interface:UserTaskService
Claim responsibility for a list of tasks, i.e. set the tasks to status Reserved- Specified by:
claim
in interfaceUserTaskService
taskIds
- list of task to be claimed
-
complete
public void complete(Long taskId, String userId, Map<String,Object> params)
Description copied from interface:UserTaskService
Complete a task with the given data- Specified by:
complete
in interfaceUserTaskService
-
complete
public void complete(String deploymentId, Long taskId, String userId, Map<String,Object> params)
Description copied from interface:UserTaskService
Complete a task with the given data- Specified by:
complete
in interfaceUserTaskService
-
completeAutoProgress
public void completeAutoProgress(Long taskId, String userId, Map<String,Object> params)
Description copied from interface:UserTaskService
Complete a task with the given data. If needed, the task is automatically claimed and/or started.- Specified by:
completeAutoProgress
in interfaceUserTaskService
-
completeAutoProgress
public void completeAutoProgress(String deploymentId, Long taskId, String userId, Map<String,Object> params)
Description copied from interface:UserTaskService
Complete a task with the given data. If needed, the task is automatically claimed and/or started.- Specified by:
completeAutoProgress
in interfaceUserTaskService
-
delegate
public void delegate(Long taskId, String userId, String targetUserId)
Description copied from interface:UserTaskService
Delegate a task from userId to targetUserId- Specified by:
delegate
in interfaceUserTaskService
-
delegate
public void delegate(String deploymentId, Long taskId, String userId, String targetUserId)
Description copied from interface:UserTaskService
Delegate a task from userId to targetUserId- Specified by:
delegate
in interfaceUserTaskService
-
exit
public void exit(Long taskId, String userId)
Description copied from interface:UserTaskService
Requesting application is no longer interested in the task output- Specified by:
exit
in interfaceUserTaskService
-
exit
public void exit(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Requesting application is no longer interested in the task output- Specified by:
exit
in interfaceUserTaskService
-
fail
public void fail(Long taskId, String userId, Map<String,Object> faultData)
Description copied from interface:UserTaskService
Actual owner completes the execution of the task raising a fault. The fault illegalOperationFault is returned if the task interface defines no faults. If fault name or fault data is not set the operation returns illegalArgumentFault.- Specified by:
fail
in interfaceUserTaskService
-
fail
public void fail(String deploymentId, Long taskId, String userId, Map<String,Object> faultData)
Description copied from interface:UserTaskService
Actual owner completes the execution of the task raising a fault. The fault illegalOperationFault is returned if the task interface defines no faults. If fault name or fault data is not set the operation returns illegalArgumentFault.- Specified by:
fail
in interfaceUserTaskService
-
forward
public void forward(Long taskId, String userId, String targetEntityId)
Description copied from interface:UserTaskService
Forward the task to another organization entity. The caller has to specify the receiving organizational entity. Potential owners can only forward a task while the task is in the Ready state. For details on forwarding human tasks refer to section 4.7.3 in WS-HumanTask_v1.pdf- Specified by:
forward
in interfaceUserTaskService
-
forward
public void forward(String deploymentId, Long taskId, String userId, String targetEntityId)
Description copied from interface:UserTaskService
Forward the task to another organization entity. The caller has to specify the receiving organizational entity. Potential owners can only forward a task while the task is in the Ready state. For details on forwarding human tasks refer to section 4.7.3 in WS-HumanTask_v1.pdf- Specified by:
forward
in interfaceUserTaskService
-
release
public void release(Long taskId, String userId)
Description copied from interface:UserTaskService
Release a previously claimed task- Specified by:
release
in interfaceUserTaskService
-
release
public void release(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Release a previously claimed task- Specified by:
release
in interfaceUserTaskService
-
resume
public void resume(Long taskId, String userId)
Description copied from interface:UserTaskService
Resume a previously suspended task- Specified by:
resume
in interfaceUserTaskService
-
resume
public void resume(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Resume a previously suspended task- Specified by:
resume
in interfaceUserTaskService
-
skip
public void skip(Long taskId, String userId)
Description copied from interface:UserTaskService
Skip a claimed task- Specified by:
skip
in interfaceUserTaskService
-
skip
public void skip(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Skip a claimed task- Specified by:
skip
in interfaceUserTaskService
-
start
public void start(Long taskId, String userId)
Description copied from interface:UserTaskService
Start the execution of the task, i.e. set the task to status InProgress.- Specified by:
start
in interfaceUserTaskService
-
start
public void start(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Start the execution of the task, i.e. set the task to status InProgress.- Specified by:
start
in interfaceUserTaskService
-
stop
public void stop(Long taskId, String userId)
Description copied from interface:UserTaskService
Cancel/stop the processing of the task. The task returns to the Reserved state.- Specified by:
stop
in interfaceUserTaskService
-
stop
public void stop(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Cancel/stop the processing of the task. The task returns to the Reserved state.- Specified by:
stop
in interfaceUserTaskService
-
suspend
public void suspend(Long taskId, String userId)
Description copied from interface:UserTaskService
Suspend a claimed task.- Specified by:
suspend
in interfaceUserTaskService
-
suspend
public void suspend(Long taskId, String userId, Map<String,Object> parameters)
Description copied from interface:UserTaskService
Suspend a claimed task with given parameters- Specified by:
suspend
in interfaceUserTaskService
-
suspend
public void suspend(String deploymentId, Long taskId, String userId)
Description copied from interface:UserTaskService
Suspend a claimed task.- Specified by:
suspend
in interfaceUserTaskService
-
suspend
public void suspend(String deploymentId, Long taskId, String userId, Map<String,Object> parameters)
Description copied from interface:UserTaskService
Suspend a claimed task.- Specified by:
suspend
in interfaceUserTaskService
-
nominate
public void nominate(Long taskId, String userId, List<org.kie.api.task.model.OrganizationalEntity> potentialOwners)
Description copied from interface:UserTaskService
Nominate a task to be handled by potentialOwners- Specified by:
nominate
in interfaceUserTaskService
-
nominate
public void nominate(String deploymentId, Long taskId, String userId, List<org.kie.api.task.model.OrganizationalEntity> potentialOwners)
Description copied from interface:UserTaskService
Nominate a task to be handled by potentialOwners- Specified by:
nominate
in interfaceUserTaskService
-
setPriority
public void setPriority(Long taskId, int priority)
Description copied from interface:UserTaskService
Sets priority of a task to given value- Specified by:
setPriority
in interfaceUserTaskService
-
setPriority
public void setPriority(String deploymentId, Long taskId, int priority)
Description copied from interface:UserTaskService
Sets priority of a task to given value- Specified by:
setPriority
in interfaceUserTaskService
-
setExpirationDate
public void setExpirationDate(Long taskId, Date date)
Description copied from interface:UserTaskService
Sets expiration date of a task to given value- Specified by:
setExpirationDate
in interfaceUserTaskService
-
setExpirationDate
public void setExpirationDate(String deploymentId, Long taskId, Date date)
Description copied from interface:UserTaskService
Sets expiration date of a task to given value- Specified by:
setExpirationDate
in interfaceUserTaskService
-
setSkipable
public void setSkipable(Long taskId, boolean skipable)
Description copied from interface:UserTaskService
Sets skipable property of a task to given value- Specified by:
setSkipable
in interfaceUserTaskService
-
setSkipable
public void setSkipable(String deploymentId, Long taskId, boolean skipable)
Description copied from interface:UserTaskService
Sets skipable property of a task to given value- Specified by:
setSkipable
in interfaceUserTaskService
-
setName
public void setName(Long taskId, String name)
Description copied from interface:UserTaskService
Sets name of the task- Specified by:
setName
in interfaceUserTaskService
-
setName
public void setName(String deploymentId, Long taskId, String name)
Description copied from interface:UserTaskService
Sets name of the task- Specified by:
setName
in interfaceUserTaskService
-
setDescription
public void setDescription(Long taskId, String description)
Description copied from interface:UserTaskService
Sets description of the task- Specified by:
setDescription
in interfaceUserTaskService
-
setDescription
public void setDescription(String deploymentId, Long taskId, String description)
Description copied from interface:UserTaskService
Sets description of the task- Specified by:
setDescription
in interfaceUserTaskService
-
saveContent
public Long saveContent(Long taskId, Map<String,Object> values)
Description copied from interface:UserTaskService
Saves gives values as content of a task, applies to task output as input cannot be altered- Specified by:
saveContent
in interfaceUserTaskService
- Returns:
-
saveContentFromUser
public Long saveContentFromUser(Long taskId, String userId, Map<String,Object> values)
Description copied from interface:UserTaskService
Saves gives values as content of a task, applies to task output as input cannot be altered- Specified by:
saveContentFromUser
in interfaceUserTaskService
- Returns:
-
saveContent
public Long saveContent(String deploymentId, Long taskId, Map<String,Object> values)
Description copied from interface:UserTaskService
Saves gives values as content of a task, applies to task output as input cannot be altered- Specified by:
saveContent
in interfaceUserTaskService
- Returns:
-
saveContent
public Long saveContent(String deploymentId, Long taskId, String userId, Map<String,Object> values)
-
deleteContent
public void deleteContent(Long taskId, Long contentId)
Description copied from interface:UserTaskService
Deletes content given bycontentId
from given task- Specified by:
deleteContent
in interfaceUserTaskService
-
deleteContent
public void deleteContent(String deploymentId, Long taskId, Long contentId)
Description copied from interface:UserTaskService
Deletes content given bycontentId
from given task- Specified by:
deleteContent
in interfaceUserTaskService
-
getTaskOutputContentByTaskId
public Map<String,Object> getTaskOutputContentByTaskId(Long taskId)
Description copied from interface:UserTaskService
Returns task output data currently stored, might be null of no data is stored- Specified by:
getTaskOutputContentByTaskId
in interfaceUserTaskService
- Returns:
-
getTaskOutputContentByTaskId
public Map<String,Object> getTaskOutputContentByTaskId(String deploymentId, Long taskId)
Description copied from interface:UserTaskService
Returns task output data currently stored, might be null of no data is stored- Specified by:
getTaskOutputContentByTaskId
in interfaceUserTaskService
- Returns:
-
getTaskInputContentByTaskId
public Map<String,Object> getTaskInputContentByTaskId(Long taskId)
Description copied from interface:UserTaskService
Returns task input data of a task- Specified by:
getTaskInputContentByTaskId
in interfaceUserTaskService
- Returns:
-
getTaskInputContentByTaskId
public Map<String,Object> getTaskInputContentByTaskId(String deploymentId, Long taskId)
Description copied from interface:UserTaskService
Returns task input data of a task- Specified by:
getTaskInputContentByTaskId
in interfaceUserTaskService
- Returns:
-
addComment
public Long addComment(Long taskId, String text, String addedBy, Date addedOn)
Description copied from interface:UserTaskService
Add comment to a task- Specified by:
addComment
in interfaceUserTaskService
- Returns:
-
addComment
public Long addComment(String deploymentId, Long taskId, String text, String addedBy, Date addedOn)
Description copied from interface:UserTaskService
Add comment to a task- Specified by:
addComment
in interfaceUserTaskService
- Returns:
-
deleteComment
public void deleteComment(Long taskId, Long commentId)
Description copied from interface:UserTaskService
Deletes comment from a task- Specified by:
deleteComment
in interfaceUserTaskService
-
deleteComment
public void deleteComment(String deploymentId, Long taskId, Long commentId)
Description copied from interface:UserTaskService
Deletes comment from a task- Specified by:
deleteComment
in interfaceUserTaskService
-
getCommentsByTaskId
public List<org.kie.api.task.model.Comment> getCommentsByTaskId(Long taskId)
Description copied from interface:UserTaskService
Get comments for a task- Specified by:
getCommentsByTaskId
in interfaceUserTaskService
- Returns:
-
getCommentsByTaskId
public List<org.kie.api.task.model.Comment> getCommentsByTaskId(String deploymentId, Long taskId)
Description copied from interface:UserTaskService
Get comments for a task- Specified by:
getCommentsByTaskId
in interfaceUserTaskService
- Returns:
-
getCommentById
public org.kie.api.task.model.Comment getCommentById(Long taskId, Long commentId)
Description copied from interface:UserTaskService
Get comment by identifier- Specified by:
getCommentById
in interfaceUserTaskService
- Returns:
-
getCommentById
public org.kie.api.task.model.Comment getCommentById(String deploymentId, Long taskId, Long commentId)
Description copied from interface:UserTaskService
Get comment by identifier- Specified by:
getCommentById
in interfaceUserTaskService
- Returns:
-
addAttachment
public Long addAttachment(Long taskId, String userId, String name, Object attachment)
Description copied from interface:UserTaskService
Add attachment to a task- Specified by:
addAttachment
in interfaceUserTaskService
- Returns:
-
addAttachment
public Long addAttachment(String deploymentId, Long taskId, String userId, String name, Object attachment)
Description copied from interface:UserTaskService
Add attachment to a task- Specified by:
addAttachment
in interfaceUserTaskService
- Returns:
-
deleteAttachment
public void deleteAttachment(Long taskId, Long attachmentId)
Description copied from interface:UserTaskService
Delete attachment from a task- Specified by:
deleteAttachment
in interfaceUserTaskService
-
deleteAttachment
public void deleteAttachment(String deploymentId, Long taskId, Long attachmentId)
Description copied from interface:UserTaskService
Delete attachment from a task- Specified by:
deleteAttachment
in interfaceUserTaskService
-
getAttachmentById
public org.kie.api.task.model.Attachment getAttachmentById(Long taskId, Long attachmentId)
Description copied from interface:UserTaskService
Get attachment by identifier- Specified by:
getAttachmentById
in interfaceUserTaskService
- Returns:
-
getAttachmentById
public org.kie.api.task.model.Attachment getAttachmentById(String deploymentId, Long taskId, Long attachmentId)
Description copied from interface:UserTaskService
Get attachment by identifier- Specified by:
getAttachmentById
in interfaceUserTaskService
- Returns:
-
getAttachmentContentById
public Object getAttachmentContentById(Long taskId, Long attachmentId)
Description copied from interface:UserTaskService
Get attachment's content by identifier- Specified by:
getAttachmentContentById
in interfaceUserTaskService
- Returns:
-
getAttachmentContentById
public Object getAttachmentContentById(String deploymentId, Long taskId, Long attachmentId)
Description copied from interface:UserTaskService
Get attachment's content by identifier- Specified by:
getAttachmentContentById
in interfaceUserTaskService
- Returns:
-
getAttachmentsByTaskId
public List<org.kie.api.task.model.Attachment> getAttachmentsByTaskId(Long taskId)
Description copied from interface:UserTaskService
Get attachments for a task- Specified by:
getAttachmentsByTaskId
in interfaceUserTaskService
- Returns:
-
getAttachmentsByTaskId
public List<org.kie.api.task.model.Attachment> getAttachmentsByTaskId(String deploymentId, Long taskId)
Description copied from interface:UserTaskService
Get attachments for a task- Specified by:
getAttachmentsByTaskId
in interfaceUserTaskService
- Returns:
-
execute
public <T> T execute(String deploymentId, org.kie.api.command.Command<T> command)
Description copied from interface:UserTaskService
Executes provided command on the underlying command executor- Specified by:
execute
in interfaceUserTaskService
- Parameters:
deploymentId
- identifier of the deployment that engine should be used for executioncommand
- actual command for execution- Returns:
- results of command execution
-
execute
public <T> T execute(String deploymentId, org.kie.api.runtime.manager.Context<?> context, org.kie.api.command.Command<T> command)
Description copied from interface:UserTaskService
Executes provided command on the underlying command executor- Specified by:
execute
in interfaceUserTaskService
- Parameters:
deploymentId
- identifier of the deployment that engine should be used for executioncontext
- context implementation to be used for getting runtime enginecommand
- actual command for execution- Returns:
- results of command execution
-
getTask
public org.kie.api.task.model.Task getTask(Long taskId)
Description copied from interface:UserTaskService
Returns task instance- Specified by:
getTask
in interfaceUserTaskService
- Returns:
-
getTask
public org.kie.api.task.model.Task getTask(String deploymentId, Long taskId)
Description copied from interface:UserTaskService
Returns task instance- Specified by:
getTask
in interfaceUserTaskService
- Returns:
-
updateTask
public void updateTask(Long taskId, String userId, UserTaskInstanceDesc userTask, Map<String,Object> inputData, Map<String,Object> outputData)
Description copied from interface:UserTaskService
Updates user task properties and data inputs and outputs. Allowed properties to be updated are:- name
- description
- priority
- expiration date
- formName
- Specified by:
updateTask
in interfaceUserTaskService
userId
- user id who is going to perform the updateuserTask
- user task with properties to be updatedinputData
- map of input variables to be added/replaced on a taskoutputData
- map of output variables to be added/replaced on a task
-
updateTask
public void updateTask(String deploymentId, Long taskId, String userId, UserTaskInstanceDesc userTask, Map<String,Object> inputData, Map<String,Object> outputData)
Description copied from interface:UserTaskService
Updates user task properties and data inputs and outputs. Allowed properties to be updated are:- name
- description
- priority
- expiration date
- formName
- Specified by:
updateTask
in interfaceUserTaskService
userId
- user id who is going to perform the updateuserTask
- user task with properties to be updatedinputData
- map of input variables to be added/replaced on a taskoutputData
- map of output variables to be added/replaced on a task
-
process
public <T> T process(T variables, ClassLoader cl)
Description copied from interface:VariablesAware
Generic processing method that might be simply returning same instance of variables if no processing is required.- Specified by:
process
in interfaceVariablesAware
- Parameters:
variables
- object that holds varialble(s)cl
- classloader that shall be used to operate on the variables e.g. project class loader- Returns:
-
disposeRuntimeEngine
protected void disposeRuntimeEngine(org.kie.api.runtime.manager.RuntimeManager manager, org.kie.api.runtime.manager.RuntimeEngine engine)
-
-