Class CreatesDuplicatesProperty

  • All Implemented Interfaces:
    PlannerProperty<Boolean>

    @API(EXPERIMENTAL)
    public class CreatesDuplicatesProperty
    extends Object
    implements PlannerProperty<Boolean>
    A property that determines whether the expression may produce duplicate entries. If the given expression is a RelationalExpression, this will return whether the expression might produce multiple instances of the same record. If the given expression is a KeyExpression, then this will return whether the expression might return multiple results for the same record.
    • Method Detail

      • evaluateAtExpression

        @Nonnull
        public Boolean evaluateAtExpression​(@Nonnull
                                            RelationalExpression expression,
                                            @Nonnull
                                            List<Boolean> childResults)
        Description copied from interface: PlannerProperty
        Evaluate the property at the given expression, using the results of evaluating the property at its children. Called on nodes in the graph in visit post-order of the depth-first traversal of the graph. That is, as each expression is visited (after all of its children have been visited, if applicable), evaluateAtExpression() is called on that expression.
        Specified by:
        evaluateAtExpression in interface PlannerProperty<Boolean>
        Parameters:
        expression - the cursor to visit
        childResults - the results of the property evaluated at the children of expression
        Returns:
        the value of property at the given expression
      • evaluateAtRef

        @Nonnull
        public Boolean evaluateAtRef​(@Nonnull
                                     ExpressionRef<? extends RelationalExpression> ref,
                                     @Nonnull
                                     List<Boolean> memberResults)
        Description copied from interface: PlannerProperty
        Evaluate the property at the given reference, using the results of evaluating the property at its members. Called on nodes in the graph in visit post-order of the depth-first traversal of the graph. That is, as each reference is visited (after all of its members have been visited, if applicable), evaluateAtRef() is called on that reference.
        Specified by:
        evaluateAtRef in interface PlannerProperty<Boolean>
        Parameters:
        ref - the expression reference to visit
        memberResults - the results of the property evaluated at the members of ref
        Returns:
        the value of property at the given reference