Interface IWorkflowEventRunner
-
- All Known Implementing Classes:
WorkflowEventRunner
public interface IWorkflowEventRunner
The workflow event runner is similar toIWorkflowTaskRunner
. The task runner is given a set of tasks and executes those; while the event runner is given an event, determines all triggers that apply to the event, finds the tasks to which these triggers belong; and finally invokes theIWorkflowTaskRunner
with those tasks.See
IWorkflowTaskRunner
for details on how tasks are executed.- Since:
- 7.0.0
- Author:
- XIMA MEDIA GmbH
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description com.google.common.collect.Table<Projekt,Vorgang,IEventExecutionResult>
triggerEvent(IWorkflowEventData eventData)
Finds allWorkflowTrigger
to which the given event applies and executes them in order.IEventExecutionResult
triggerFormRecordEvent(IFormRecordProvidingEvent eventData)
Similar totriggerEvent(IWorkflowEventData)
, but for an event that pertains to a specificVorgang
.
-
-
-
Method Detail
-
triggerEvent
com.google.common.collect.Table<Projekt,Vorgang,IEventExecutionResult> triggerEvent(IWorkflowEventData eventData) throws WorkflowEventRunnerException
Finds allWorkflowTrigger
to which the given event applies and executes them in order. Note that an event may apply to multiple form records or event form records of different projects. All applicable form records are grouped by the project they belong to, and executed in that order. Returns the workflow result for each form record, grouped first by theProjekt
, then by theVorgang
.- Parameters:
eventData
- Data of the event to run.- Returns:
- The result of the workflow execution for each form record, grouped first by the project of the form record and then by the form record itself.
- Throws:
WorkflowEventRunnerException
- When an unhandled exception while attempting to execute the workflow. Note that this does not include errors in the configured workflow tasks themselves (such as when an email could not be sent)-- useIEventExecutionResult.getException()
to check for the result of each workflow task.
-
triggerFormRecordEvent
IEventExecutionResult triggerFormRecordEvent(IFormRecordProvidingEvent eventData)
Similar totriggerEvent(IWorkflowEventData)
, but for an event that pertains to a specificVorgang
. This guarantees that only the tasks of that specific form record are executed. Returns the result for that form record.- Parameters:
eventData
- Event data for a form record specific event.- Returns:
- The result of running the tasks of the triggers that were triggered by the given event.
-
-