Class PdfASmartCopy

    • Method Detail

      • copyIndirect

        protected PdfIndirectReference copyIndirect​(PRIndirectReference in)
                                             throws java.io.IOException,
                                                    BadPdfFormatException
        Description copied from class: PdfCopy
        Translate a PRIndirectReference to a PdfIndirectReference In addition, translates the object numbers, and copies the referenced object to the output file. NB: PRIndirectReferences (and PRIndirectObjects) really need to know what file they came from, because each file has its own namespace. The translation we do from their namespace to ours is *at best* heuristic, and guaranteed to fail under some circumstances.
        Overrides:
        copyIndirect in class PdfCopy
        Throws:
        java.io.IOException
        BadPdfFormatException
      • freeReader

        public void freeReader​(PdfReader reader)
                        throws java.io.IOException
        Description copied from class: PdfWriter
        Use this method to writes the reader to the document and free the memory used by it. The main use is when concatenating multiple documents to keep the memory usage restricted to the current appending document.
        Overrides:
        freeReader in class PdfCopy
        Parameters:
        reader - the PdfReader to free
        Throws:
        java.io.IOException - on error