[
https://issues.apache.org/jira/browse/PDFBOX-4554?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16853367#comment-16853367
]
Jason Pyeron commented on PDFBOX-4554:
--------------------------------------
I know that!
{code}
MessageDigest d = MessageDigest.getInstance(algo);
for (int i=0; i<buf.length; ++i)
d.update(buf[i].array(),buf[i].position(), buf[i].remaining());
return d.digest();
{code}
Almost everywhere (outside of PDFBox) they are prepared to work with multiple
ByteBuffer or multiple byte[] - either way you could easily use CMSProcessable
& CMSReadable.
> operations taking a byte[] need to allow for offset and length too
> ------------------------------------------------------------------
>
> Key: PDFBOX-4554
> URL: https://issues.apache.org/jira/browse/PDFBOX-4554
> Project: PDFBox
> Issue Type: Improvement
> Reporter: Jason Pyeron
> Priority: Major
>
> Without this, massive amounts of memory must be copied/allocated to "trim"
> byte[].
> See forthcoming pull request.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]