Interface IDecisionTableColumn

  • All Known Implementing Classes:
    ADispatcherTableColumn, ArrayParameterColumn, SimpleParameterColumn

    public interface IDecisionTableColumn
    The abstraction that represents the column(it may be a row in transparent view) of the decision table. Decision table column contains next cells:
    1. Column type
    2. Code expression
    3. Parameter declaration
    4. Title
    5. Number of rules one by one
    Check the next example:
    Column type C1 C2
    Code expression paramLocal1==paramInc paramLocal2==paramInc
    Parameter declaration String paramLocal1 String paramLocal2
    Title Local Param 1 Local Param 2
    Rule #1 value11 value21
    Rule #2 value12 value22
    Rule #3 value13 value23
    Author:
    DLiauchuk
    • Method Detail

      • getColumnType

        String getColumnType()
        Gets the type of the column. For more information see DecisionTableColumnHeaders
        Returns:
        string representation type of the column.
      • getCodeExpression

        String getCodeExpression()
        Gets the string representation of the code expression cell(the next cell after column type definition see getColumnType()).
        Returns:
        string representation of the code expression cell.
      • getParameterDeclaration

        String getParameterDeclaration()
        Gets the string representation of the parameter declaration cell(the next cell after code expression cell seegetCodeExpression()).
        Returns:
        the string representation of the parameter declaration cell
      • getTitle

        String getTitle()
        Gets the string representation of the title(business name) cell(the next cell after the parameter declaration cell seegetParameterDeclaration()).
        Returns:
        the string representation of the title(business name) cell
      • getRuleValue

        String getRuleValue​(int ruleIndex,
                            int localParameterIndex)
        As condition may has several local parameters see getNumberOfLocalParameters(), so the rule values is a matrix, where first index is the rule index, the second - the index of local parameter. If the getNumberOfLocalParameters() is more than 1, use this method to get all rule values.
        Parameters:
        ruleIndex - index of the rule
        localParameterIndex - index of the local parameter
        Returns:
        the value for the appropriate rule and local parameter
      • getNumberOfLocalParameters

        int getNumberOfLocalParameters()
        Condition may has several local parameters. See example.
        C1
        paramLocal1 == paramIncome || paramLocal2 == paramIncome
        String paramLocal1 String paramLocal2
        Local Parameter number one Local Parameter number two
        value11 value21
        value12 value22
        Returns: