PdfProcessorTask

Represents a processing task for PdfProcessor.

Types

Link copied to clipboard
Describes how an annotation will be processed by a processor.

Functions

Link copied to clipboard
open fun addCanvasDrawingToPage(@NonNull pageCanvas: PageCanvas, destinationPageIndex: Int): PdfProcessorTask
Merges content of canvas drawing on top (or below) the destination page content.
Link copied to clipboard
open fun addImageToPage(@NonNull image: PageImage, destinationPageIndex: Int): PdfProcessorTask
Adds an image on top (or below) the destination page content.
Link copied to clipboard
open fun addNewPage(@NonNull newPage: NewPage, @IntRange(from = 0) destinationPageIndex: Int): PdfProcessorTask
Adds a new page to the document at passed index.
Link copied to clipboard
Applies the redact annotations for the given page index.
Link copied to clipboard
Changes ALL annotations in document according to AnnotationProcessingMode.
Link copied to clipboard
Changes passed annotations according to passed AnnotationProcessingMode.
Link copied to clipboard
Changes all annotation of a certain type according to the passed in processing mode.
Link copied to clipboard
Changes all form annotations of a certain type according to the passed in processing mode.
Link copied to clipboard
Adjusts color of all strokes on the given page.
Link copied to clipboard
Removes all page labels in the document.
Link copied to clipboard
Creates a new empty processing task for the PdfProcessor.
Link copied to clipboard
Creates a new processing task for the PdfProcessor.
Link copied to clipboard
open fun keepPages(@NonNull pagesToKeep: Set<Integer>): PdfProcessorTask
Keeps only passed pages from document.
Link copied to clipboard
open fun mergePage(@NonNull pagePdf: PagePdf, destinationPageIndex: Int): PdfProcessorTask
Merges a page with a page of the task's document.
open fun mergePage(@NonNull pagePdf: PagePdf, destinationPageIndex: Int, @NonNull blendMode: BlendMode): PdfProcessorTask
Merges a page with a page of the task's document by using specified BlendMode.
Link copied to clipboard
open fun movePages(@NonNull pagesToMove: Set<Integer>, @IntRange(from = 0) destinationIndex: Int): PdfProcessorTask
Moves passed pages to a new index in the document.
Link copied to clipboard
Creates a new processing task for creating a new single-page document from scratch.
Link copied to clipboard
open fun performOcrOnPages(@NonNull pageIndexes: Set<Integer>, @NonNull ocrLanguage: OcrLanguage): PdfProcessorTask
Performs optical character recognition on the provided set of pages in the PDF document.
Link copied to clipboard
open fun removePages(@NonNull pagesToRemove: Set<Integer>): PdfProcessorTask
Removes passed pages from document.
Link copied to clipboard
open fun resizePage(@IntRange(from = 0) pageIndex: Int, @NonNull pageSize: Size): PdfProcessorTask
Re-sizes the selected page to pageSize.
Link copied to clipboard
open fun rotatePage(@IntRange(from = 0) pageIndex: Int, @IntRange(from = "-270", to = 270) rotation: Int): PdfProcessorTask
Rotates the selected page for passed degrees.
Link copied to clipboard
open fun setFormFieldNameMappings(@NonNull formFieldNameMappings: Map<String, String>): PdfProcessorTask
Renames form fields as described in a mapping.
Link copied to clipboard
open fun setFormMappingNameMappings(@NonNull formMappingNameMappings: Map<String, String>): PdfProcessorTask
Renames form mapping names as described in this mapping.
Link copied to clipboard
open fun setPageBox(@IntRange(from = 0) pageIndex: Int, @NonNull boxToChange: PdfBox, @NonNull rectF: RectF): PdfProcessorTask
Changes one of the page boxes for the passed page.
Link copied to clipboard
open fun setPageLabel(@IntRange(from = 0) pageIndex: Int, @Nullable label: String): PdfProcessorTask
Sets a label on the page.
Link copied to clipboard
open fun stripEmptyPages(stripEmptyPages: Boolean): PdfProcessorTask
Strip empty pages at the end of processing.
Link copied to clipboard
Sets metadata for the output document.