I have some xml that I cannot change the names of the nodes. I'd like
to create a custom binding class so that I can create more API
friendly names to retrieve the data, or do some post processing on the
data.
The only example I could find does not act on the XML that is being
parsed by the bindery class (
http://wiki.xml3k.org/Amara/Manual#custom-
binding-classes). Could someone please provide a binding class method
that would allow me to access a node by a different name, such as:
XML = '<xml>
<someTerribleName>
'this is a test'
</someTerribleName>
</xml>'
doc = amara.parse(XML, binding_classes={(None, u'foo'):
specialized_class})
doc.someNiceName # outputs 'this is a test'
Thanks.