Class PathConstraintRange


  • public class PathConstraintRange
    extends PathConstraintMultiValue
    A constraint that restrict a path to a particular relationship with a set of ranges.
    Author:
    Alex Kalderimis
    • Field Detail

      • VALID_OPS

        public static final java.util.Set<ConstraintOp> VALID_OPS
        List of valid ops for this type of constraint
    • Constructor Detail

      • PathConstraintRange

        public PathConstraintRange​(java.lang.String path,
                                   ConstraintOp op,
                                   java.util.Collection<java.lang.String> ranges)
        Constructs a new PathConstraintRange. The path should be a normal path expression with dots separating the parts. Do not use colons to represent outer joins, and do not use square brackets to represent subclass constraints. The path will be checked for format, but can only be verified once inside a PathQuery object by the PathQuery.verifyQuery() method. This object is used to form a constraint on an attribute.
        Parameters:
        path - the path that the constraint is attached to
        op - the type of operation
        ranges - the value to constrain to, as a String - it will be validated later when the query is validated, as we do not know the attribute type at this stage.
        Throws:
        java.lang.NullPointerException - if path, op, or value are null
        java.lang.IllegalArgumentException - if the path contains colons or square brackets, or is otherwise in a bad format, or if the op is invalid for this constraint type