pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jochen Hebbrecht <jochenhebbre...@gmail.com>
Subject Performance issue in LucenePDFDocument? All data in 1 String?
Date Thu, 14 Jun 2012 12:51:09 GMT
Hi all,

I see the following lines in
http://svn.apache.org/repos/asf/pdfbox/trunk/lucene/src/main/java/org/apache/pdfbox/lucene/LucenePDFDocument.java

...
stripper.writeText( pdfDocument, writer );

// Note: the buffer to string operation is costless;
// the char array value of the writer buffer and the content string
// is shared as long as the buffer content is not modified, which will
// not occur here.

String contents = writer.getBuffer().toString();
...

Can somebody explain me the "Note:" which is attached to these lines?
I'm worried about performance in case of large PDF's. Is all text
stored in the single String object? Wouldn't this lead to performance
issues?

Kind regards,

Jochen

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message