Class LikeConstraint

    • Constructor Detail

      • LikeConstraint

        public LikeConstraint​(DynamicOperand operand1,
                              Value operand2,
                              SelectorImpl selector)
                       throws RepositoryException
        Creates a new like constraint.
        Parameters:
        operand1 - the dynamic operand.
        operand2 - the static operand.
        selector - the selector for the dynamic operand.
        Throws:
        RepositoryException - if an error occurs reading the string value from the static operand.
    • Method Detail

      • evaluate

        protected boolean evaluate​(Value op1)
                            throws RepositoryException
        Evaluates this constraint for the given dynamic operand value op1.
        Overrides:
        evaluate in class ComparisonConstraint
        Parameters:
        op1 - the current value of the dynamic operand.
        Returns:
        true if the given value satisfies the constraint.
        Throws:
        RepositoryException - if an error occurs while converting the values.