Class ProcessEngineTemplate

java.lang.Object
com.aquima.interactions.test.templates.AbstractReportingTemplate
com.aquima.interactions.test.templates.process.ProcessEngineTemplate

public class ProcessEngineTemplate extends AbstractReportingTemplate
Template that may be used to initialize a process engine.
Since:
7.1
Author:
O. Kerpershoek
  • Constructor Details

    • ProcessEngineTemplate

      public ProcessEngineTemplate()
      Default constructor that generates a new initialization report.
    • ProcessEngineTemplate

      public ProcessEngineTemplate(com.aquima.interactions.foundation.report.IInitializationReport report)
      Constructs the template with the initialization report that should be used.
      Parameters:
      report - The report that should be used to log errors and warnings to.
  • Method Details

    • isEnabled

      public boolean isEnabled()
      This method returns a boolean indicating if the process engine should be enabled for the application.
      Returns:
      boolean indicating if the process engine should be enabled for the application.
    • addProcess

      public ProcessTemplate addProcess(String name, String type)
      This method may be used to add a process definition to the process engine template.
      Parameters:
      name - The name of the process that should be added.
      type - The type of the process that should be added.
      Returns:
      Template representing the newly added process.
    • addProcess

      public ProcessTemplate addProcess(String name, String type, com.aquima.interactions.foundation.GUID id)
      This method may be used to add a process definition to the process engine template.

      This variant of the method also allows setting the persistency id (node id) of the root process task. This is required in situations where the process engine template needs to be re-created but still be able to use existing processes and tasks in the case dao. Without specifying a constant node id for the root process task, a new id will be generated each time the process engine template is instantiated.

      Parameters:
      name - The name of the process that should be added.
      type - The type of the process that should be added
      id - the nodeId of the root process task
      Returns:
      Template representing the newly added process.
    • addProcessType

      public ProcessTypeTemplate addProcessType(String name)
      This method may be used to add a process type definition.
      Parameters:
      name - The name of the type that should be added.
      Returns:
      Template for the newly added process type.
    • addProcessTask

      public ProcessTaskTemplate addProcessTask(String name)
      This method may be used to add a process task definition.
      Parameters:
      name - The name of the task that should be added.
      Returns:
      Template for the newly added process task.
    • addAuthorizationAlgorithm

      public AuthorizationAlgorithmTemplate addAuthorizationAlgorithm(String name, boolean external)
      This method may be used to add an authorization algorithm to the process engine.
      Parameters:
      name - The name of the algorithm.
      external - Indicator whether the algorithm should be external.
      Returns:
      A template for modifying the algorithm.
    • addAuthorizationAlgorithm

      public AuthorizationAlgorithmTemplate addAuthorizationAlgorithm(String name, boolean external, String unauthorizedUsersExpression)
      This method may be used to add an authorization algorithm to the process engine.
      Parameters:
      name - The name of the algorithm.
      external - Indicator whether the algorithm should be external.
      unauthorizedUsersExpression - Expression that contains restricted user identifiers.
      Returns:
      A template for modifying the algorithm.
    • addPriorityAlgorithm

      public PriorityAlgorithmTemplate addPriorityAlgorithm(String name, boolean external, com.aquima.interactions.process.impl.ReevaluationTime reevaluationTime, String startTimeExpression)
      This method may be used to add an priority algorithm to the process engine, with the default re-evaluation event.
      Parameters:
      name - The name of the algorithm.
      external - Indicator whether the algorithm should be external.
      reevaluationTime - The re-evaluation time unit.
      Returns:
      A template for modifying the algorithm.
    • addPriorityAlgorithm

      public PriorityAlgorithmTemplate addPriorityAlgorithm(String name, boolean external, com.aquima.interactions.process.impl.ReevaluationTime reevaluationTime, com.aquima.interactions.process.impl.ReevaluationEvent reevaluationEvent, String startTimeExpression)
      This method may be used to add an priority algorithm to the process engine.
      Parameters:
      name - The name of the algorithm.
      external - Indicator whether the algorithm should be external.
      reevaluationTime - The re-evaluation time unit.
      reevaluationEvent - The re-evaluation event.
      Returns:
      A template for modifying the algorithm.
    • addRoutingAlgorithm

      public RoutingAlgorithmTemplate addRoutingAlgorithm(String name, boolean external)
      This method may be used to add a routing algorithm definition to the process engine.
      Parameters:
      name - The name of the routing algorithm that should be added.
      external - Is external
      Returns:
      Template representing the newly added routing algorithm.
    • addRoutingAlgorithm

      public RoutingAlgorithmTemplate addRoutingAlgorithm(String name, boolean external, com.aquima.interactions.process.impl.ReevaluationEvent reevaluationEvent)
      This method may be used to add a routing algorithm definition to the process engine.
      Parameters:
      name - The name of the routing algorithm that should be added.
      external - Is external
      reevaluationEvent - The reevaluationEvent
      Returns:
      Template representing the newly added routing algorithm.
    • addRoutingAlgorithm

      public RoutingAlgorithmTemplate addRoutingAlgorithm(String name, boolean external, com.aquima.interactions.process.impl.ReevaluationEvent reevaluationEvent, boolean userOverwritingEnabled)
      This method may be used to add a routing algorithm definition to the process engine.
      Parameters:
      name - The name of the routing algorithm that should be added.
      external - Is external
      reevaluationEvent - The reevaluationEvent
      userOverwritingEnabled - Enable overwriting of the user assignee task assignee by routing algorithm
      Returns:
      Template representing the newly added routing algorithm.
    • addProcessEvent

      public ProcessEventTemplate addProcessEvent(String name)
      This method may be used to add a process event definition to the process engine.
      Parameters:
      name - The name of the process event that should be added.
      Returns:
      Template representing the newly added process event.
    • addMessageEvent

      public MessageEventTemplate addMessageEvent(String name)
      This method may be used to add a message event definition to the process engine.
      Parameters:
      name - The name of the message event.
      Returns:
      The template representing the newly added message event.
    • toDataSource

      public com.aquima.interactions.process.ds.IProcessEngineDS toDataSource()
      This method converts the template to a data source that can be used to initialize a process engine.
      Returns:
      a data source that can be used to initialize a process engine.