Hi all,
i checked the PDSignature object and come accross the methods getContents and getSignedContent. I think this both methods need realy a better solution.

I also remind that the saveIncremental method need also a rewrite.

This will be only possible with something like the RandomAccessFile. Some file from which we can create Input- and OutputStreams to work with it.

Adam wrote in the PDFBOX-912 Issue (from 03/Jan/11 00:56) [1] that he is implementing such a stucture. *@Adam, how far are you with the implementation? can i help you? or can you provide me the code and i will try to continue your work.*

My idea is to rewrite the PDDocument load-method and wrote the input in a file instead of using a InputStream. Then provide the PDFParser an InputStream created from the RandomAccessFile and parse the document.

The secound idea is to use this file for the COSDictionaries. Something like parsing the Dictionary only when the user will access it. So the Dictionary only carry a reference to the object. Don't know if this is possible or will slow down the parse process, so i will sit down and analyse the possible optimizations.

Maybe someone have other nice ideas for RandomAccessFile usage.

Best regards
Thomas

[1] https://issues.apache.org/jira/browse/PDFBOX-912?focusedCommentId=12976589&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-12976589


Reply via email to