[Scribus] XML parser in Perl
avox
avox
Sun Jun 11 17:54:12 CEST 2006
Gregory Pittman wrote:
>
> Andreas invited comments in his blog post:
> http://rants.scribus.net/2006/06/06/do-you-enjoy-parsing-xml/
>
Gregory,
I wasn't really asking which PL I should use for parsing! :-)
For loading Scribus docs we will (have to) use C/C++ anyway.
Also, parsing per se isn't the big problem, there are lots of decent XML
parsers outside. Some PLs have them even as standard modules (Java,
Perl, Python, ...).
The problem is what you do with the data you parsed. You have the choice
between:
* using plain DOM, which only has generic node elements
* using a XML->C++ binding, which usually implies using a codegenerator for
your datastructures
* building your own datastructures, either from DOM or from the SAX stream.
My article was focusing on the last possibility. The first & second aren't
feasible
for Scribus. Currently Scribus parses a document into a DOM tree and than
creates it's own datastructures from this DOM tree, which is ugly and slow.
/Andreas
--
View this message in context: http://www.nabble.com/XML-parser-in-Perl-t1769952.html#a4817561
Sent from the Scribus forum at Nabble.com.
More information about the scribus
mailing list