Class LocalInputSource


  • public class LocalInputSource
    extends Object
    A source document for Mindee API operations.
    • Method Detail

      • getPDFInputOperator

        protected PDFInputOperation getPDFInputOperator()
        Get the PDFInputOperation instance. Override this method to provide custom PDF input handling.
        Returns:
        PDFInputOperation instance
      • getPDFCompressor

        protected PDFCompression getPDFCompressor()
        Get the PDFCompression instance. Override this method to provide custom PDF compression handling.
        Returns:
        PDFCompression instance
      • getPageCount

        public int getPageCount()
                         throws IOException
        Get the number of pages in the document.
        Returns:
        the number of pages in the current file.
        Throws:
        IOException - If an I/O error occurs during the PDF operation.
      • applyPageOptions

        public void applyPageOptions​(PageOptions pageOptions)
                              throws IOException
        Applies PDF-specific operations on the current file based on the specified PageOptions.
        Parameters:
        pageOptions - The options specifying which pages to modify or retain in the PDF file.
        Throws:
        IOException - If an I/O error occurs during the PDF operation.
      • isPDF

        public boolean isPDF()
        Returns true if the file is a PDF.
      • compress

        public void compress​(int quality,
                             boolean forceSourceText,
                             boolean disableSourceText)
                      throws IOException
        Throws:
        IOException
      • getFile

        public byte[] getFile()
      • getFilename

        public String getFilename()