xml.* getting the hang...
merkosh at hadiko.de
Sun Jun 9 12:09:41 CEST 2002
i am working myself into the xml.* packages and am just about to start
getting an idea of what works together with what in wich order.
basically i want to read in xml packages from a byte stream and from
these "request" objects i want to create frame-response xml objects,
just taking the attributes of a request object and copy them into a
response object, leaving the rest blank.
i figured that xml.sax and xml.parsers.expat is where to look for.
problem number first:
- in order to build an xml dom object i have to get started on a
Document(); and this is the problem: i couldn't find anything; with one
exception, i can create xml documents using xml.dom.minidom.Document(),
if this is the regular case then i don't quite see how xml.sax.* and
xml.dom.minidom relate to eachother. it feels strange if i use functions
from various packages when i'd expect them to be of importance for all
sub packages. any expenations?
Secondly i found the package xml.dom.pulldom which seems to be just what
i'm looking for, however the documentation is very poor on these classe.
what, f.e. is a "documentFactory"?
I don't want to do xml validating, so xml.parsers.expat could be used,
too. So now i don't know what to use at all:
1. xml.parsers.expat: i don't do validating
2. xml.dom.pulldom: i want to create partial dom trees from sax events
3. xml.sax.xmlreader.IncrementalParser(): i read xml from a byte stream
Any idea or comments on this?
Thanks in advance
More information about the Python-list