Re: [xml] [PATCH] inverted SAX



On Thu, Apr 04, 2002 at 04:39:18PM +0200, Fernand Albarracin wrote:
Hi,

Here is a patch for libxml2-2.4.19 that implement an "inverted SAX" dump
method. As you can see, it doesn't modify any single line of code (only

  Thanks, I'm not able to review it at the moment, but I will try to answer
some of your questions.

- attributes : it's strange, it seems that there is two ways to handle
  them

  * call the attributeSAXFunc callback for each attribute,
  (http://www.xmlsoft.org/html/libxml-parser.html#ATTRIBUTESAXFUNC)
  unfortunately there is no attibute field in xmlSAXHandler

  * build an array composed of all attributes, give it to the
  startElementSAXFunc callback, destroy it

  The first one is not part of SAX it's an internal function of the SAX
module (well it should), the interface is really to build the array and
pass it to startElement

- namespace handling : well, I'm not sure what should be done here

  * can we just discard namespace information ?

  * can we consider it as an attribute (xmlns...) ?

  You must provide them as attribute, and not forget to build the
name for elements and attributes accordingly.

   More when I'm back from Sevilla,

Daniel

-- 
Daniel Veillard      | Red Hat Network https://rhn.redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]