-----BEGIN PGP SIGNED MESSAGE-----
On 08/21/2012 11:37 AM, saurabh prakash wrote:
colander's job in deserialization is to validate the "cstruct" (a Python
data structure extracted from whatever format, usually consisting of
sequences or mappings of strings) against a schema, converting it (if
validation succeeds) into an "appstruct" (a loosely equivalent data
structure, but with values massaged into their "canonical" form.
> If anyone has used colander for xml deserialization can you just put
E.g., for the example here:
> a snippet here on its usage? It would be very helpful.
a corresponding XML document might be::
Your code would be responsible for converting the XML document into the
'cstruct' (which the linked example generates imperatively), before
passing the 'cstruct' to the 'schema.deserialize' method, from which it
would get back the 'appstruct'. You are free to use whatever tools you
like for parsing the XML and constructing the appstruct. I would be
likely to use lxml.
Hope this helps,
Tres Seaver +1 540-429-0999 tsea...@palladion.com
Palladion Software "Excellence by Design" http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
-----END PGP SIGNATURE-----