Sounds reasonable. Can you offer any insights into the shared string table? It looks like the shared string ID in a sheet(n).xml file is simply the index of the string in the table. That suggests to me a simple Java vector might be a suitable implementation with not only low memory use but also constant lookup time; don't even need a map.

I was hoping the SharedStringTable type might be an interface but no luck.

chris...

Nick Burch wrote:
On Wed, 6 May 2009, Chris Lott wrote:
So my next question is, is there something especially memory hungry in the shared strings table builder? Is there anything I can do here? Would you like me to write a bug?

The SharedStringsTable helper on XSSFReader is a full XMLBeans powered class. This made it much quicker to write, but does mean it'll use more memory. Also, because it's a read-write class (used by XSSFWorkbook too), it keeps many more references than are needed for just reading in a file

If you have the time, I'd suggest writing a purely sax, read only shared strings table helper for use with XSSFReader. One of those ought to be able to process the strings in a much lower memory footprint, and ought to be fairly quick to write as the shared strings part is such a simple format

Nick

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to