Class DecisionTableTemplate

java.lang.Object
com.aquima.interactions.test.templates.AbstractReportingTemplate
com.aquima.interactions.test.templates.rules.DecisionTableTemplate

public class DecisionTableTemplate extends AbstractReportingTemplate
Template that can be used to initialize decision tables.
Since:
6.0
Author:
O. Kerpershoek
  • Constructor Details

    • DecisionTableTemplate

      public DecisionTableTemplate(com.aquima.interactions.foundation.report.IInitializationReport report, String name)
      Constructs the template with the required parameters.
      Parameters:
      report - the report to add errors and warnings during initialization.
      name - The name of the decision table.
  • Method Details

    • getName

      protected String getName()
    • addCondition

      public ConditionTemplate addCondition(String expression, String alternative)
      This method may be used to add a condition to the decision table.
      Parameters:
      expression - The condition expression (RHS).
      alternative - The value (expression) against which the condition result should be checked (LHS).
      Returns:
      Condition template that represents the condition that was added.
    • getConditions

      protected List<ConditionTemplate> getConditions()
    • addRuleGroup

      public void addRuleGroup(String name)
      This method may be used to specify the name of a rule group the rule should belong to.
      Parameters:
      name - The name of the group that this rule should be part of.
    • getRuleGroupNames

      protected String[] getRuleGroupNames()
    • toDataSource

      public com.aquima.interactions.rule.ds.table.IDecisionTableDS toDataSource()
      This method converts the template to a data source that can be used to initialize a decision table.
      Returns:
      a data source that can be used to initialize a decision table.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object