Package org.verapdf.gf.model
Class GFModelParser
java.lang.Object
org.verapdf.gf.model.GFModelParser
- All Implemented Interfaces:
Closeable,AutoCloseable,Component,PDFAParser
- Author:
- Timur Kamalov
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()static GFModelParsercreateModelWithFlavour(File pdfFile, PDFAFlavour flavour) static GFModelParsercreateModelWithFlavour(File pdfFile, PDFAFlavour flavour, String password) static GFModelParsercreateModelWithFlavour(File pdfFile, PDFAFlavour flavour, PDFAFlavour defaultFlavour) static GFModelParsercreateModelWithFlavour(File pdfFile, PDFAFlavour flavour, PDFAFlavour defaultFlavour, String password) static GFModelParsercreateModelWithFlavour(InputStream toLoad, PDFAFlavour flavour) static GFModelParsercreateModelWithFlavour(InputStream toLoad, PDFAFlavour flavour, String password) static GFModelParsercreateModelWithFlavour(InputStream toLoad, PDFAFlavour flavour, PDFAFlavour defaultFlavour) static GFModelParsercreateModelWithFlavour(InputStream toLoad, PDFAFlavour flavour, PDFAFlavour defaultFlavour, String password) getFeatures(FeatureExtractorConfig config) getFeatures(FeatureExtractorConfig config, List<AbstractFeaturesExtractor> extractors) GetPDDocumentobject for current file.getRoot()Method return root object of model implementation from greenfield model together with the hierarchy.
-
Method Details
-
createModelWithFlavour
public static GFModelParser createModelWithFlavour(InputStream toLoad, PDFAFlavour flavour) throws ModelParsingException, EncryptedPdfException -
createModelWithFlavour
public static GFModelParser createModelWithFlavour(InputStream toLoad, PDFAFlavour flavour, PDFAFlavour defaultFlavour) throws ModelParsingException, EncryptedPdfException -
createModelWithFlavour
public static GFModelParser createModelWithFlavour(InputStream toLoad, PDFAFlavour flavour, String password) throws ModelParsingException, EncryptedPdfException -
createModelWithFlavour
public static GFModelParser createModelWithFlavour(InputStream toLoad, PDFAFlavour flavour, PDFAFlavour defaultFlavour, String password) throws ModelParsingException, EncryptedPdfException -
createModelWithFlavour
public static GFModelParser createModelWithFlavour(File pdfFile, PDFAFlavour flavour) throws ModelParsingException, EncryptedPdfException -
createModelWithFlavour
public static GFModelParser createModelWithFlavour(File pdfFile, PDFAFlavour flavour, PDFAFlavour defaultFlavour) throws ModelParsingException, EncryptedPdfException -
createModelWithFlavour
public static GFModelParser createModelWithFlavour(File pdfFile, PDFAFlavour flavour, String password) throws ModelParsingException, EncryptedPdfException -
createModelWithFlavour
public static GFModelParser createModelWithFlavour(File pdfFile, PDFAFlavour flavour, PDFAFlavour defaultFlavour, String password) throws ModelParsingException, EncryptedPdfException -
getPDDocument
GetPDDocumentobject for current file.- Returns:
PDDocumentobject of greenfield library.- Throws:
IOException- when target file is not pdf or pdf file is not contain root object
-
getRoot
Method return root object of model implementation from greenfield model together with the hierarchy.- Specified by:
getRootin interfacePDFAParser- Returns:
- root object representing by
CosDocument - Throws:
IOException- when target file is not pdf or pdf file is not contain root object
-
getDetails
- Specified by:
getDetailsin interfaceComponent
-
getFlavour
- Specified by:
getFlavourin interfacePDFAParser- Returns:
PDFAFlavourfor the model that has been parsed
-
getPDFDocument
- Specified by:
getPDFDocumentin interfacePDFAParser- Returns:
- the
PDFDocumentparsed.
-
getFeatures
- Specified by:
getFeaturesin interfacePDFAParser- Parameters:
config- aFeatureExtractorConfigthat denotes the features to be extracted.- Returns:
- features collection of the document as a
FeatureExtractionResult
-
getFeatures
public FeatureExtractionResult getFeatures(FeatureExtractorConfig config, List<AbstractFeaturesExtractor> extractors) - Specified by:
getFeaturesin interfacePDFAParser- Parameters:
config- aFeatureExtractorConfigthat denotes the features to be extracted.extractors- extractors for features reporting- Returns:
- features collection of the document as a
FeatureExtractionResult
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-