Package org.verapdf.pdfa
Class AbstractFoundry
- java.lang.Object
-
- org.verapdf.pdfa.AbstractFoundry
-
- All Implemented Interfaces:
Closeable,AutoCloseable,Component,VeraPDFFoundry
public abstract class AbstractFoundry extends Object implements VeraPDFFoundry
- Version:
- 0.1 Created 26 Oct 2016:21:25:17
- Author:
- Carl Wilson carlwilson AT github
-
-
Constructor Summary
Constructors Constructor Description AbstractFoundry()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()PDFAValidatorcreateFailFastValidator(PDFAFlavour flavour, int maxFailures)Creates a newPDFAValidatorinitialised with the passed profile, requested fast failing behaviour and configured NOT to log passed checks.PDFAValidatorcreateFailFastValidator(ValidationProfile profile, int maxFailures)Creates a newPDFAValidatorinitialised with the passed profile, requested fast failing behaviour and configured NOT to log passed checks.PDFAValidatorcreateValidator(PDFAFlavour flavour, boolean logSuccess)Creates a newPDFAValidatorinstance that uses one of theValidationProfiles packaged as a core library resource.PDFAValidatorcreateValidator(PDFAFlavour flavour, int maxNumberOfDisplayedFailedChecks, boolean logSuccess, boolean showErrorMessages)PDFAValidatorcreateValidator(ValidationProfile profile, boolean logSuccess)Creates a newPDFAValidatorinitialised with the passed profile and chosen passed test logging.PDFAValidatorcreateValidator(ValidationProfile profile, int maxNumberOfDisplayedFailedChecks, boolean logSuccess, boolean showErrorMessages)PDFAValidatorcreateValidator(ValidatorConfig config)Obtain a newPDFAValidatorinstance.PDFAValidatorcreateValidator(ValidatorConfig config, PDFAFlavour flavour)Obtain a newPDFAValidatorinstance that uses a customPDFAFlavour.PDFAValidatorcreateValidator(ValidatorConfig config, ValidationProfile profile)Obtain a newPDFAValidatorinstance that uses a customValidationProfileinstance.PDFAFlavourdefaultFlavour()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.verapdf.component.Component
getDetails
-
Methods inherited from interface org.verapdf.pdfa.VeraPDFFoundry
createMetadataFixer, createParser, createParser, createParser, createParser, createParser, getParserId
-
-
-
-
Method Detail
-
createValidator
public PDFAValidator createValidator(ValidatorConfig config)
Description copied from interface:VeraPDFFoundryObtain a newPDFAValidatorinstance.- Specified by:
createValidatorin interfaceVeraPDFFoundry- Parameters:
config- aValidatorConfiginstance used to configure thePDFAValidator- Returns:
- an appropriately configured
PDFAValidatorinstance.
-
createValidator
public PDFAValidator createValidator(ValidatorConfig config, PDFAFlavour flavour)
Description copied from interface:VeraPDFFoundryObtain a newPDFAValidatorinstance that uses a customPDFAFlavour.- Specified by:
createValidatorin interfaceVeraPDFFoundry- Parameters:
config- aValidatorConfiginstance used to configure thePDFAValidatorflavour- the particularPDFAFlavourto validated against.- Returns:
- an appropriately configured
PDFAValidatorinstance.
-
createValidator
public PDFAValidator createValidator(ValidatorConfig config, ValidationProfile profile)
Description copied from interface:VeraPDFFoundryObtain a newPDFAValidatorinstance that uses a customValidationProfileinstance.- Specified by:
createValidatorin interfaceVeraPDFFoundry- Parameters:
config- aValidatorConfiginstance used to configure thePDFAValidator- Returns:
- an appropriately configured
PDFAValidatorinstance.
-
createValidator
public PDFAValidator createValidator(PDFAFlavour flavour, boolean logSuccess)
Description copied from interface:VeraPDFFoundryCreates a newPDFAValidatorinstance that uses one of theValidationProfiles packaged as a core library resource. While these profiles are not guaranteed to be up to date, they are available when offline. AProfileDirectorypopulated with the pre-loaded profiles can be obtained by callingProfiles#getVeraProfileDirectory().- Specified by:
createValidatorin interfaceVeraPDFFoundry- Parameters:
flavour- thePDFAFlavourthat's associated with theValidationProfileto used to initialise thePDFAValidator.logSuccess-booleanused to configure logging of passed tests by thePDFAValidator. Passtrueto log passed tests,falseto only log tests that don't pass.- Returns:
- a
PDFAValidatorinstance initialised from the passed parameters
-
createValidator
public PDFAValidator createValidator(ValidationProfile profile, boolean logSuccess)
Description copied from interface:VeraPDFFoundryCreates a newPDFAValidatorinitialised with the passed profile and chosen passed test logging.- Specified by:
createValidatorin interfaceVeraPDFFoundry- Parameters:
profile- theValidationProfileto be enforced by the returnedPDFAValidator.logSuccess-booleanused to configure logging of passed tests by thePDFAValidator. Passtrueto log passed tests,falseto only log tests that don't pass.- Returns:
- a
PDFAValidatorinstance initialised from the passed parameters
-
createValidator
public PDFAValidator createValidator(PDFAFlavour flavour, int maxNumberOfDisplayedFailedChecks, boolean logSuccess, boolean showErrorMessages)
- Specified by:
createValidatorin interfaceVeraPDFFoundry
-
createValidator
public PDFAValidator createValidator(ValidationProfile profile, int maxNumberOfDisplayedFailedChecks, boolean logSuccess, boolean showErrorMessages)
- Specified by:
createValidatorin interfaceVeraPDFFoundry
-
createFailFastValidator
public PDFAValidator createFailFastValidator(PDFAFlavour flavour, int maxFailures)
Description copied from interface:VeraPDFFoundryCreates a newPDFAValidatorinitialised with the passed profile, requested fast failing behaviour and configured NOT to log passed checks.- Specified by:
createFailFastValidatorin interfaceVeraPDFFoundry- Parameters:
flavour- thePDFAFlavourthat's associated with theValidationProfileto used to initialise thePDFAValidator.maxFailures- anintvalue that configures thePDFAValidatorto abort validation aftermaxFailuresfailed tests. IfmaxFailuresis less than 1 then thePDFAValidatorwill complete the full validation process.- Returns:
- a
PDFAValidatorinstance initialised from the passed parameters
-
createFailFastValidator
public PDFAValidator createFailFastValidator(ValidationProfile profile, int maxFailures)
Description copied from interface:VeraPDFFoundryCreates a newPDFAValidatorinitialised with the passed profile, requested fast failing behaviour and configured NOT to log passed checks.- Specified by:
createFailFastValidatorin interfaceVeraPDFFoundry- Parameters:
profile- theValidationProfileto be enforced by the returnedPDFAValidator.maxFailures- anintvalue that configures thePDFAValidatorto abort validation aftermaxFailuresfailed tests. IfmaxFailuresis less than 1 then thePDFAValidatorwill complete the full validation process.- Returns:
- a
PDFAValidatorinstance initialised from the passed parameters
-
defaultFlavour
public PDFAFlavour defaultFlavour()
- Specified by:
defaultFlavourin interfaceVeraPDFFoundry- Returns:
- the default
PDFAFlavourset for thisVeraPDFFoundry
-
close
public void close()
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
-