Interface UserRequestHandler
- All Known Implementing Classes:
FlowableUserRequestHandler
public interface UserRequestHandler
-
Method Summary
Modifier and TypeMethodDescriptionvoid
cancel
(ProcessInstance procInst, String reason) Cancel a running user request.void
cancelByProcessDefinition
(String processDefinitionId) Cancel all running user requests for the given process definition id.void
cancelByUser
(EntityLifecycleEvent<Entity> event) Cancel all running user requests for the user in the given delete event.Claim a form for a given object.Get the form matching the provided task id.org.springframework.data.domain.Page
<UserRequestForm> Get the forms matching the provided parameters.org.springframework.data.domain.Page
<UserRequest> getUserRequests
(String userKey, org.springframework.data.domain.Pageable pageable) Get the running user requests matching the provided parameters.Parses the given execution id to find matching user request and owner.start
(String bpmnProcess, User user, WorkflowTaskExecInput inputVariables) Starts a new user request, for the given BPMN process and user.submitForm
(UserRequestForm form) Submit a form.unclaimForm
(String taskId) Unclaim a form for a given object.
-
Method Details
-
getUserRequests
org.springframework.data.domain.Page<UserRequest> getUserRequests(String userKey, org.springframework.data.domain.Pageable pageable) Get the running user requests matching the provided parameters.- Parameters:
userKey
- user key (optional)pageable
- paging information- Returns:
- total number of user requests, list of user requests matching the provided parameters
-
start
Starts a new user request, for the given BPMN process and user.- Parameters:
bpmnProcess
- BPMN processuser
- userinputVariables
- variables- Returns:
- data about the started request service, including execution id
-
parse
Parses the given execution id to find matching user request and owner.- Parameters:
executionId
- execution id- Returns:
- matching user request and owner
-
cancel
Cancel a running user request.- Parameters:
procInst
- process instance for user requestreason
- reason to cancel the user request
-
cancelByProcessDefinition
Cancel all running user requests for the given process definition id.- Parameters:
processDefinitionId
- process definition id
-
cancelByUser
Cancel all running user requests for the user in the given delete event.- Parameters:
event
- delete event
-
getForm
Get the form matching the provided task id.- Parameters:
userKey
- user keytaskId
- task id- Returns:
- the form for the given task id
-
getForms
org.springframework.data.domain.Page<UserRequestForm> getForms(String userKey, org.springframework.data.domain.Pageable pageable) Get the forms matching the provided parameters.- Parameters:
userKey
- user key (optional)pageable
- paging information- Returns:
- total number of forms, list of forms matching the provided parameters
-
claimForm
Claim a form for a given object.- Parameters:
taskId
- Workflow task to which the form is associated- Returns:
- updated form
-
unclaimForm
Unclaim a form for a given object.- Parameters:
taskId
- Workflow task to which the form is associated- Returns:
- updated form
-
submitForm
Submit a form.- Parameters:
form
- to be submitted- Returns:
- user updated by this form submit
-