Addon:Lxml Gramplet

From Gramps
Revision as of 10:10, 2 October 2011 by Romjerome (talk | contribs) (Created page with "* [http://lxml.de/ lxml] is a Pythonic binding for the C libraries libxml2 and libxslt. Know for good performances by using C-level ([http://www.cython.org/ Cython]). * [[Gramps ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
  • lxml is a Pythonic binding for the C libraries libxml2 and libxslt. Know for good performances by using C-level (Cython).
  • GRAMPS_XML file format is robust and well [GRAMPS_XML#Gramps_XML_Resources documented].


The idea of this experimental lxml gramplet is to provide a way for using basic lxml features with Gramps XML files.

XPath, Xslt, RelaxNG validation can be done by lxml, which provides an API very close to etree ElementTree module from python.

The experimental lxml gramplet aims to use these lxml features by parsing a Gramps XML file generated by Gramps 3.3.x and to generate an output sample, using open W3C technologies.

You can get a copy of this draft from Addon repository:

http://gramps-addons.svn.sourceforge.net/viewvc/gramps-addons/branches/gramps33/contrib/lxml

Currently, this addon explores multiple ways. Feel free for modifying for your own use.