Is generating possible in Xerces C++?



I'm using Xerces C++ to generate some XML. I'm having a hard time finding documentation or examples of how to add an "<?xml-model ..." element to the prolog.


Here's an example of XML I want to generate:



<?xml version="1.0"?>
<?xml-model href="http://ift.tt/1sdc4K4"?>
<book xmlns="http://ift.tt/15UgvhS">

</book>


To generate my document, I'm using code like this:



XMLPlatformUtils::Initialize();
_domImpl = DOMImplementationRegistry::getDOMImplementation(XMLString::transcode("core"));
XMLCh* ROOTNAME = XMLString::transcode("book");
_doc = _domImpl->createDocument(0, ROOTNAME, 0);


Is adding the <?xml-model..> possible with Xerces, and if so are there any examples?


Thanks, Galen


No comments:

Post a Comment