On 7/11/07, Jochen Wiedmann <[EMAIL PROTECTED]> wrote:
It took me about 4 hours to create the patch for MIME4J-19. (Pull parser API) Given my experiences with commons-fileupload, I believe it would take another 6 hours or so to rewrite MIME4J-19 a second time in order to use a single, buffered InputStream, which would even be able to provide information like line and column number and byte offset.
This sounds very promising. I had to work on parsing a huge XML doc that would have been impossible with DOM, and SAX is a pain to use. I found the StAX parser [1] that is available in Java 6, and it's a cursor based/pull-style XML parser. I found the pattern to be very very effective and seems like it could address identical issues that affect mime parsing. I'm not sure if/how they handle writing/modilfying XML documents, but might be interesting to see how they address that for Mime4j. It looks like this is one of the rare JCP groups that actually did a good job collecting (rather than inventing) requirements and solutions. [1] http://www.javabeat.net/javabeat/java6/articles/2007/06/java-6-0-new-features-part-2/2 -- Serge Knystautas Lokitech >> software . strategy . design >> http://www.lokitech.com p. 301.656.5501 e. [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
