[XML-SIG] Python Wrapper for Xerces/Xalan

Martin v. Loewis martin@loewis.home.cs.tu-berlin.de
Thu, 12 Apr 2001 19:08:10 +0200


> Thanks. Those tools look very interesting, but doesn't FourThought
> offer pretty much the same or even a superset of these tools ?

Yes, Xerces is pretty much the same functionality as PyXML, and Xalan
is what 4XSLT does (unless I mix them up right now). However, the hope
of people who want such integration typically is that:

- it will be faster than the pure Python code. That should be true
  for the validating parser (i.e. I'd hope that Xerces beats xmlproc
  in parsing speed), and might be true for the DOM implementation
  (although I'd wait for completion of the project to see whether this
  is actually the case).

- it will be more correct than PyXML, since there is more developer
  power behind Xerces - especially since that got supported by the
  Apache foundation. I'm not sure here; AFAIK, xmlproc is still one of
  the most complete parsers with regard to catalogs and such stuff, and
  4DOM supports almost all of DOM Level 2 - which Xerces didn't, last
  I checked.

> BTW, the ICU OSS project (*) hosted by IBM seems an interesting target
> for Python as well -- now that we have Unicode-support in the
> core, I guess hooking up Python with ICU should be easy ;-)

I think one of the problems with ICU is that you have to use their
string types, so quite some copying forth and back might go on when
you try to integrate that into Python. Also, it will be tricky to make
the integration seemless - users might have to use ICU functions,
instead of getting transparent access to codeset converters and locale
information.

As for codeset converters, this, again, is an area where some speed
advantage might be gained from using ICU - if you can avoid too much
copying.

Regards,
Martin