[NeXML]
Rich phyloinformatic dataThe future data exchange standard is here!
NeXML is an exchange standard for representing phyloinformatic data — inspired by the commonly used NEXUS format, but more robust and easier to process.
Cpp
Prerequisites
C++ bindings are generated from the nexml schema files using the xsd
tool from CodeSynthesis,
and are then compiled with something like the driver.cxx file to yield
an executable that processes nexml instance documents (presumably this would be part of an importer
that maps the beans objects created by the xsd tool onto your internal object model).
The basic steps are as follows:
- Download and install xsd-* for your platform.
- Download and install xerces-c, we need to include its headers during compiling and libxerces during linking.
-
Generate the headers and binding sources from the schema using the xsd tool. The easiest way to do this is to run the
configurescript in the parent directory and use make from that directory (if you are a developer, you will have to run thebootstrap.shshell script to create theconfigurescript -- you will also need up-to-dateautoconfandautomake). You will need to use the--with-xerces=and--with-code-syn-xsdarguments toconfigureIf you do not want to use the configure-based build, you can also build the C++ bindings using something like this shell script or this Makefile. You may have to tweak these a little depending on your install location and version for xsd and xerces-c. The salient point in these script examples is the command line invocation for
xsd. -
Create your own mappings between the xsd object model and that of your software. The
driver.cxx gives a simple example of where to start with that.
Make sure to use the flags to include and link to xsd, and xerces.
For example, compile with
-I$XERCES_HOME/include -I$XSD_HOME/$XSD_HOME/libxsdand link with-L$XERCES_HOME/lib -lxerces-c.
https://nexml.svn.sourceforge.net/svnroot/nexml/trunk/nexml/cpp/ \
cpp
Name Last modified Size Description
Parent Directory - Folder
Makefile.am 22-Feb-2009 16:07 3.9K Make file
build.sh 26-Oct-2010 08:21 1.3K Unix shell script
cpp-bindings.tar 24-Feb-2009 19:41 72K Tar (tape) archive
handwrittenMakefile 17-Dec-2008 14:31 1.0K Make file