Class WorkflowEventRunner

java.lang.Object
de.xima.fc.workflow.processor.engine.WorkflowEventRunner
All Implemented Interfaces:
IWorkflowEventRunner

public final class WorkflowEventRunner extends Object implements IWorkflowEventRunner
Default implementation of the IWorkflowEventRunner. Create a new instance via the constructor, which currently does not required any parameters. You can then trigger an event and have the corresponding tasks be executed.
Since:
7.0.0
Author:
XIMA MEDIA GmbH
  • Method Details

    • triggerEvent

      public com.google.common.collect.Table<Projekt,Vorgang,IEventExecutionResult> triggerEvent(IWorkflowEventData eventData)
      Description copied from interface: IWorkflowEventRunner
      Finds all WorkflowTrigger 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 the Projekt, then by the Vorgang.
      Specified by:
      triggerEvent in interface IWorkflowEventRunner
      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.
    • triggerFormRecordEvent

      public IEventExecutionResult triggerFormRecordEvent(IFormRecordProvidingEvent eventData)
      Description copied from interface: IWorkflowEventRunner
      Similar to IWorkflowEventRunner.triggerEvent(IWorkflowEventData), but for an event that pertains to a specific Vorgang. This guarantees that only the tasks of that specific form record are executed. Returns the result for that form record.
      Specified by:
      triggerFormRecordEvent in interface IWorkflowEventRunner
      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.
    • newInstance

      public static IWorkflowEventRunner newInstance()
      Returns:
      A new instance of a workflow event runner for running the tasks triggered by an event.