Interface DocumentValidator

    • Method Detail

      • validate

        ValidationResult validate​(byte[] source)
                           throws ValidatorException
        Validate the given XML source against the validation file and return a new ValidationResult instance
        Parameters:
        source - The XML source to validate
        Returns:
        A newly initialized ValidationResult containing the results of the validation
        Throws:
        ValidatorException - Thrown when there is an error performing the validation
      • validate

        ValidationResult validate​(byte[] source,
                                  ValidationResult result)
                           throws ValidatorException
        Validate the given XML source against the validation file, and add the errors and warnings to the given ValidationResult item.
        Parameters:
        source - The XML source to validate
        result - Errors and warnings are added to this instance in-place
        Returns:
        The modified ValidationResult instance
        Throws:
        ValidatorException - Thrown when there is an error performing the validation