Package com.adobe.granite.workflow.rule
Interface RuleEngine
public interface RuleEngine
provides a way to implement custom rule engines in the Workflow engine
-
Method Summary
Modifier and TypeMethodDescriptionbooleancanEvaluate(String rule) Indicates if the rule in question can be evaluated by this rule enginebooleanevaluate(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 datadata- the associated Workflow data for the rule being evaluatedworkflowSession- the workflow session- Returns:
- true if the rule evaluated to true, false otherwise
- Throws:
WorkflowException- in case there's a failure during evaluation
-
canEvaluate
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
-