Interface RuleEngine


public interface RuleEngine
provides a way to implement custom rule engines in the Workflow engine
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Indicates if the rule in question can be evaluated by this rule engine
    boolean
    evaluate(String rule, WorkflowData data, WorkflowSession workflowSession)
    Evaluate a rule.
  • Method Details

    • evaluate

      boolean evaluate(String rule, WorkflowData data, WorkflowSession workflowSession) throws WorkflowException
      Evaluate a rule.
      Parameters:
      rule - the rule data
      data - the associated Workflow data for the rule being evaluated
      workflowSession - the workflow session
      Returns:
      true if the rule evaluated to true, false otherwise
      Throws:
      WorkflowException - in case there's a failure during evaluation
    • canEvaluate

      boolean canEvaluate(String rule)
      Indicates if the rule in question can be evaluated by this rule engine
      Parameters:
      rule - the rule to be evaluated
      Returns:
      true if this rule engine can handle this rule