Class PdfImageExtractor
java.lang.Object
de.xima.fc.testhelper.pdf.PdfImageExtractor
Extracts images from a PDF document.
- Since:
- 8.2.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <Container>
ContainerextractImagesFromPdf(org.apache.pdfbox.pdmodel.PDDocument document, Collector<? super org.apache.pdfbox.pdmodel.graphics.image.PDImageXObject, ?, ? extends Container> collector) Extracts images from a PDF document and collects them using the provided collector.
-
Constructor Details
-
PdfImageExtractor
public PdfImageExtractor()
-
-
Method Details
-
extractImagesFromPdf
public static <Container> Container extractImagesFromPdf(org.apache.pdfbox.pdmodel.PDDocument document, Collector<? super org.apache.pdfbox.pdmodel.graphics.image.PDImageXObject, ?, ? extends Container> collector) throws IOException Extracts images from a PDF document and collects them using the provided collector.- Type Parameters:
Container- The type of the container that the collector collects the images into.- Parameters:
document- The PDF document to extract images from.collector- The collector to collect the images with.- Returns:
- The result of the collector.
- Throws:
IOException- If an I/O error occurs while extracting the images.
-