[XML-SIG] parsing xml schema

Martin v. Loewis martin@v.loewis.de
Thu, 22 Nov 2001 09:16:52 +0100


> Is it possible to validate and parse a xml-schema file and get structured
> data in python objects?

Parsing it is no problem; any Python parser will do. Validating it is
currently not supported in PyXML; you may want to try XSV - see the
PyXML "other software" page for a reference.

> I would like to write a python class which have functions to get the
> structured data by parsing the xml-schema file. And pass this info to
> wxPython objects.

If you merely want to get the data, then I would suggest that
validation is not needed. In this case, I'd recommend to build a DOM
tree, e.g. using

tree = xml.dom.minidom.parse(resource)

and then either use DOM accessors or XPath to get the data.

Regards,
Martin