ANN: pygenx 0.5.3

Michael Twomey mick@translucentcode.org
Thu, 01 Jul 2004 13:04:23 +0100


pygenx 0.5.3 is now available:

http://software.translucentcode.org/pygenx/pygenx-0.5.3.tar.gz

http://software.translucentcode.org/pygenx/

What is it?
-----------

pygenx is a wrapper for the genx[1] canonical[2] XML generation library.

If you need a simple, fast, way of generating correct XML without
worrying about escaping characters or character entities then pygenx is
ideal.

What's changed?
---------------

In 0.5.3 I've changed the handling of files so any python class 
implementing flush() and write() methods should work now (including 
StringIO). Previously they had to contain a pointer to a C FILE struct.

I've also written a manual, which can be found in the distribution and 
online: http://software.translucentcode.org/pygenx/manual.html

Other small bugs have been fixed as well.

Example
-------

#!/usr/bin/env python

import genx

writer = genx.Writer()
fp = file("greeting.xml", "w")
writer.startDocFile(fp)
writer.startElementLiteral("greeting")
writer.addText("Hello world!")
writer.endElement()
writer.endDocument()

greeting.xml:

<greeting>Hello world!</greeting>


mick