generateFromImageRefs

abstract fun generateFromImageRefs(images: List<ImageRef>, pdfConfig: PdfConfiguration = PdfConfiguration.default(), sourceOcrPages: List<Page> = emptyList()): Result<File>

Creates sandwiched OCR PDF file from given ImageRefs and provided source list of Page OCR data.

Return

Result.Success with generated PDF File if PDF was generated successfully, Result.Failure otherwise

Parameters

images

list of source ImageRefs

pdfConfig

the PDF configuration

sourceOcrPages

the source list of Page OCR data


abstract fun generateFromImageRefs(images: List<ImageRef>, outputFile: File, pdfConfig: PdfConfiguration = PdfConfiguration.default(), sourceOcrPages: List<Page> = emptyList()): Result<Unit>

Creates sandwiched OCR PDF file from given ImageRefs and provided source list of Page OCR data.

Return

Result.Success if PDF was generated successfully, Result.Failure otherwise

Parameters

images

list of source ImageRefs

outputFile

the output PDF file

pdfConfig

the PDF configuration

sourceOcrPages

the source list of Page OCR data