diff options
Diffstat (limited to 'xsd-examples/cxx/tree/wildcard/README')
-rw-r--r-- | xsd-examples/cxx/tree/wildcard/README | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/xsd-examples/cxx/tree/wildcard/README b/xsd-examples/cxx/tree/wildcard/README index d451509..8b89774 100644 --- a/xsd-examples/cxx/tree/wildcard/README +++ b/xsd-examples/cxx/tree/wildcard/README @@ -19,7 +19,14 @@ email.cxx C++ types that represent the given vocabulary, a set of parsing functions that convert XML instance documents to a tree-like in-memory object model, and a set of serialization functions that convert the - object model back to XML. These are generated by XSD from email.xsd. + object model back to XML. + + These files are generated by the XSD compiler from email.xsd using the + following command line: + + xsd cxx-tree --generate-wildcard --generate-serialization \ + --root-element message email.xsd + Note that the --generate-wildcard option is used to request the wildcard mapping. @@ -29,6 +36,16 @@ driver.cxx the content of the object model to STDERR. Next the driver creates a reply email which is then serialized to XML. -To run the example on the sample XML instance document simply execute: +To compile and link the example manually from the command line we can use +the following commands (replace 'c++' with your C++ compiler name): + +c++ -DXSD_CXX11 -c email.cxx +c++ -DXSD_CXX11 -c driver.cxx +c++ -o driver driver.o email.o -lxerces-c + +Note that we need to define the XSD_CXX11 preprocessor macro since the +source code includes libxsd headers directly. + +To run the example on the sample XML instance document execute: -$ ./driver email.xml +./driver email.xml |