Re: XML::LibXML: How to tell parse_balanced_chunk what DTD to use?
Reuben Thomas <[email protected]> Fri, 17 Sep 2010 11:51:50 +0100
| Newsgroups | gmane.comp.lang.perl.xml |
|---|---|
| Message-ID | <[email protected]> |
On 17 September 2010 11:13, Robin Berjon <[email protected]> wrote: > On Sep 16, 2010, at 15:20 , Reuben Thomas wrote: >>> If there's a way of doing that, I'm not aware of it. >> >> So does that mean there's no way to use parse_balanced_chunk on XML >> that contains non-default entity references? That seems a bit odd... > > None that I know of, but there could be some way I haven't thought of. You might think it strange, but parse_balanced_chunk isn't a typical XML parser functionality in the first place so I wouldn't be surprised if it weren't all that generic. Sure, but the underlying libxml2 API would seem to support this functionality; at least it has the information it needs: int xmlParseBalancedChunkMemory (xmlDocPtr doc, xmlSAXHandlerPtr sax, void * user_data, int depth, const xmlChar * string, xmlNodePtr * lst) In particular, it takes a doc, whereas parse_balanced_chunk is a parser method, not a document method. -- http://rrt.sc3d.org _______________________________________________ Perl-XML mailing list [email protected] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs