Class Operators.ListOperator

    • Constructor Detail

      • ListOperator

        public ListOperator​(java.lang.String persistName,
                            java.lang.String displayName,
                            java.lang.String displayNameInExpression)
    • Method Detail

      • getToStringPart

        public java.lang.String getToStringPart​(java.util.List<DFTerm> operands,
                                                int index)
        Description copied from class: DFOperator
        Get the part of the complete DFOperator.toString(java.util.List) method result. This method can be overriden by subclasses so each operator can provide specific form of String representation.

        For example for binary operator is this method called 3 times: for indexes 0, 1 and 2. The index=0 means it's string before the first operand, index=1 is string between operands and index=2 is after the second operand. For operator LESS_THAN it should return: index=0 => "", index=1 => " less than ", and for index=2 => "".

        This method allow subclass to reuse the generic code from DFOperator.toString(java.util.List) and change the own notation (e.g. "[molW < 15]" => "[< moW, 15]" etc.).

        getToStringPart in class DFOperator
        operands - The list of all operands
        index - The index of String [0..operands.size()]
        The indexed part of whole DFOperator.toString(java.util.List) method.