public class ScriptTaskListener extends ActivitiScriptBase implements org.activiti.engine.delegate.TaskListener
TaskListener
that runs the script against the ScriptService
.
The script that is executed can be set using field 'script'. A non-default
script-processor can be set in the field 'scriptProcessor'. Optionally, you can run
the script as a different user than the default by setting the field 'runAs'.
By default, the user this script is executed with is the task's assignee. If no
assignee is set, the current logged-in user is used. If no user is currently logged in
(eg. flow triggered by timer) the system user will be used instead.EXECUTION_BINDING_NAME, PERSON_BINDING_NAME, runAs, script, scriptProcessor, USERHOME_BINDING_NAME
Constructor and Description |
---|
ScriptTaskListener() |
Modifier and Type | Method and Description |
---|---|
protected Map<String,Object> |
getInputMap(org.activiti.engine.delegate.DelegateTask delegateTask,
String runAsUser) |
void |
notify(org.activiti.engine.delegate.DelegateTask delegateTask) |
executeScript, executeScript, executeScriptAsUser, getPersonNode, getServiceRegistry, getStringValue, setRunAs, setScript, setScriptProcessor
Copyright © 2005–2017 Alfresco Software. All rights reserved.