Interface IDefaultRuleDS

All Superinterfaces:
IReportingDS, IRuleDS
All Known Implementing Classes:
ReportingDefaultRuleDS, XmlDefaultRuleDS, XmlDefaultRuleDS

public interface IDefaultRuleDS extends IRuleDS
Interface for a data source object that can be used to initialize an attribute default.
Since:
5.0
Author:
O. Kerpershoek
  • Method Details

    • getAttributeName

      String getAttributeName()
      This method returns the name of the attribute the default is defined for.
      Returns:
      The name of the attribute the default is defined for.
    • getType

      DefaultRuleType getType()
      This method returns the type of the default. Depending on the type either the getValue, getDecisionTableDS or the getExpression method will be invoked.
      Returns:
      The type of the default.
    • getValue

      IValue getValue()
      This method returns the value that should be used as default. The value is only used when the data source returns the DefaultRuleType.VALUE as type.
      Returns:
      The value that should be used as default.
      Throws:
      ConversionException - This exception is raised when the value for the default could not be initialized.
    • getDecisionTableTableDS

      IDecisionTableDS getDecisionTableTableDS()
      This method returns the data source for the decision table that should be used as default. The value is only used when the data source returns the DefaultRuleType.TABLE as type.
      Returns:
      The data source for the decision table that should be used as default.
    • getExpression

      String getExpression()
      This method returns the expression that should be used as default. The value is only used when the data source returns the DefaultRuleType.EXPRESSION as type.
      Returns:
      The expression that should be used as default.
    • getRuleName

      String getRuleName()
      This method returns the name of the (custom) rule that should be used as default. The rule name is only used when the data source returns the DefaultRuleType.EXTERNAL as type.
      Returns:
      the name of the (custom) rule that should be used as default.
    • iterateJustifications

      void iterateJustifications(IJustificationVisitor visitor)
      This method should iterate all the justification texts that are available for this rule, and add them to the supplied visitor.
      Parameters:
      visitor - The visitor to which the justifications of this rule should be added.
      Throws:
      InitializationException - This exception is thrown when an invalid justification is added.