Class AnalysisResult
The PDF/A analysis result
Result of the validator's method Validator.analyze(com.pdftools.pdf.Document) which is required for the conversion to PDF/A with pdftools.pdfa.conversion.Converter.convert.
Note that AnalysisResult objects remain valid as long as their pdftools.pdf.Document has not been closed and the analysis result has not been used in pdftools.pdfa.conversion.Converter.convert.
-
Method Summary
Modifier and TypeMethodDescriptionThe conformance used for analysis (Getter)intThe number of fonts used in the document (Getter)booleanWhether the document contains embedded files (Getter)booleanWhether the document is conforming (Getter)booleanWhether the document should be converted to PDF/A (Getter)booleanWhether the document is digitally signed (Getter)The recommended conversion conformance (Getter)Methods inherited from class com.pdftools.internal.NativeObject
equals, hashCode
-
Method Details
-
getConformance
The conformance used for analysis (Getter)
The PDF/A level might differ from the
AnalysisOptions.getConformance(). If the claimed PDF/A level of the input document is higher thanAnalysisOptions.getConformance(), the higher level is used forgetConformance().For example, if
AnalysisOptions.getConformance()is PDF/A-2b, but the document's claimed conformance is PDF/A-2u, the analysis checks if the document actually conforms to its claimed conformance PDF/A-2u. Because otherwise a conversion is required. -
getRecommendedConformance
The recommended conversion conformance (Getter)
The optimal PDF/A conformance for the conversion (i.e. thepdftools.pdfa.conversion.ConversionOptions.getConformance). The recommended conformance level might be higher than the analysis conformance, if the document actually contains all data required for the higher level. It might also be lower, if the document is missing some required data. -
getIsConversionRecommended
public boolean getIsConversionRecommended()Whether the document should be converted to PDF/A (Getter)
A conversion is generally recommended in the following cases:
-
If
getIsConforming()isfalse, i.e. if the document does not conform to thegetConformance(). - If the document is conforming, but other issues are found for which a conversion is highly recommended. For example, if certain corner cases of the specification are detected.
Note that in certain processes it might also be beneficial to convert a document if its conformance does not match the
getRecommendedConformance(). This will actually upgrade the PDF/A level of the input document. -
If
-
getIsConforming
public boolean getIsConforming()Whether the document is conforming (Getter)
Whether the document conforms to thegetConformance(). Note that even if this property returnstruea conversion might still be recommended as indicated bygetIsConversionRecommended(). -
getIsSigned
public boolean getIsSigned()Whether the document is digitally signed (Getter)
-
getHasEmbeddedFiles
public boolean getHasEmbeddedFiles()Whether the document contains embedded files (Getter)
-
getFontCount
public int getFontCount()The number of fonts used in the document (Getter)
-