Class TypeConstraint

    • Constructor Detail

    • Method Detail

      • validate

        public boolean validate​(Object object)
        Description copied from interface: Constraint
        Validates the given object against this constraint.

        If some object is null. Constraint should return true while validating unless the constraint deals with nullable state.

        Parameters:
        object - the object to validate
        Returns:
        true if the object was successfully validated, false otherwise
      • getType

        public Type getType()
        Returns:
        The type used by this constraint to validate.
        Since:
        7.1
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object