Class ValidatorFactory

    • Method Detail

      • createValidator

        public static PDFAValidator createValidator​(PDFAFlavour flavour,
                                                    boolean logPassedChecks)
        Creates a new PDFAValidator instance that uses one of the ValidationProfiles packaged as a core library resource. While these profiles are not guaranteed to be up to date, they are available when offline. A ProfileDirectory populated with the pre-loaded profiles can be obtained by calling Profiles.getVeraProfileDirectory().
        Parameters:
        flavour - the PDFAFlavour that's associated with the ValidationProfile to used to initialise the PDFAValidator.
        logPassedChecks - boolean used to configure logging of passed tests by the PDFAValidator. Pass true to log passed tests, false to only log tests that don't pass.
        Returns:
        a PDFAValidator instance initialised from the passed parameters
      • createValidator

        public static PDFAValidator createValidator​(PDFAFlavour flavour,
                                                    int maxNumberOfDisplayedFailedChecks,
                                                    boolean logPassedChecks,
                                                    boolean showErrorMessages)
      • createValidator

        public static PDFAValidator createValidator​(PDFAFlavour flavour,
                                                    boolean logPassedChecks,
                                                    int maxFailures)
        Creates a new PDFAValidator instance that uses one of the ValidationProfiles packaged as a core library resource, see Validators#createValidator(PDFAFlavour, boolean).
        Parameters:
        flavour - the PDFAFlavour that's associated with the ValidationProfile to used to initialise the PDFAValidator.
        logPassedChecks - boolean used to configure logging of passed tests by the PDFAValidator. Pass true to log passed tests, false to only log tests that don't pass.
        maxFailures - an int value that configures the PDFAValidator to abort validation after maxFailures failed tests. If maxFailures is less than 1 then the PDFAValidator will complete the full validation process.
        Returns:
        a PDFAValidator instance initialised from the passed parameters
      • createValidator

        public static PDFAValidator createValidator​(PDFAFlavour flavour,
                                                    boolean logPassedChecks,
                                                    int maxFailures,
                                                    boolean showErrorMessages)
      • createValidator

        public static PDFAValidator createValidator​(ValidationProfile profile,
                                                    boolean logPassedChecks)
        Creates a new PDFAValidator initialised with the passed profile and chosen passed test logging.
        Parameters:
        profile - the ValidationProfile to be enforced by the returned PDFAValidator.
        logPassedChecks - boolean used to configure logging of passed tests by the PDFAValidator. Pass true to log passed tests, false to only log tests that don't pass.
        Returns:
        a PDFAValidator instance initialised from the passed parameters
      • createValidator

        public static PDFAValidator createValidator​(ValidationProfile profile,
                                                    int maxNumberOfDisplayedFailedChecks,
                                                    boolean logPassedChecks,
                                                    boolean showErrorMessages)
      • createValidator

        public static PDFAValidator createValidator​(ValidationProfile profile,
                                                    int maxFailures)
        Creates a new PDFAValidator initialised with the passed profile, requested fast failing behaviour and configured NOT to log passed checks.
        Parameters:
        profile - the ValidationProfile to be enforced by the returned PDFAValidator.
        maxFailures - an int value that configures the PDFAValidator to abort validation after maxFailures failed tests. If maxFailures is less than 1 then the PDFAValidator will complete the full validation process.
        Returns:
        a PDFAValidator instance initialised from the passed parameters
      • createValidator

        public static PDFAValidator createValidator​(PDFAFlavour flavour,
                                                    int maxFailures)
        Creates a new PDFAValidator initialised with the passed profile, requested fast failing behaviour and configured NOT to log passed checks.
        Parameters:
        flavour - the PDFAFlavour that's associated with the ValidationProfile to used to initialise the PDFAValidator.
        maxFailures - an int value that configures the PDFAValidator to abort validation after maxFailures failed tests. If maxFailures is less than 1 then the PDFAValidator will complete the full validation process.
        Returns:
        a PDFAValidator instance initialised from the passed parameters
      • createValidator

        public static PDFAValidator createValidator​(ValidationProfile profile,
                                                    boolean logPassedChecks,
                                                    int maxFailures)
        Creates a new PDFAValidator initialised with the passed profile, chosen passed test logging and requested fast failing behaviour.
        Parameters:
        profile - the ValidationProfile to be enforced by the returned PDFAValidator.
        logPassedChecks - boolean used to configure logging of passed tests by the PDFAValidator. Pass true to log passed tests, false to only log tests that don't pass.
        maxFailures - an int value that configures the PDFAValidator to abort validation after maxFailures failed tests. If maxFailures is less than 1 then the PDFAValidator will complete the full validation process.
        Returns:
        a PDFAValidator instance initialised from the passed parameters
      • createValidator

        public static PDFAValidator createValidator​(ValidationProfile profile,
                                                    boolean logPassedChecks,
                                                    int maxFailures,
                                                    boolean showErrorMessages)
      • createConfig

        public static ValidatorConfig createConfig​(PDFAFlavour flavour,
                                                   boolean recordPasses,
                                                   int maxFails,
                                                   boolean debug)
        Create a ValidatorConfig instance from the passed values.
        Parameters:
        flavour - the PDFAFlavour used for validation
        recordPasses - a boolean parameter, set true to record passed checks, false to only record failed checks.
        maxFails - an int value for the number of failed checks encountered before ending validation.
        Returns:
        a new ValidatorConfig instance created from the passed values.
      • createConfig

        public static ValidatorConfig createConfig​(PDFAFlavour flavour,
                                                   boolean recordPasses,
                                                   int maxFails,
                                                   boolean debug,
                                                   boolean isLogsEnabled,
                                                   Level loggingLevel)
      • createConfig

        public static ValidatorConfig createConfig​(PDFAFlavour flavour,
                                                   PDFAFlavour defaultFlavour,
                                                   boolean recordPasses,
                                                   int maxFails,
                                                   boolean debug,
                                                   boolean isLogsEnabled,
                                                   Level loggingLevel,
                                                   int maxNumberOfDisplayedFailedChecks,
                                                   boolean showErrorMessages)