diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2014-07-23 15:21:29 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2014-07-23 15:21:29 +0200 |
commit | bada6666c70977a058755ccf232e7d67b24adeed (patch) | |
tree | 1e92d50cebce96abaf9bce19e36026c47f77b9ba /xsd/examples/cxx/tree/messaging/dom-serialize.cxx | |
parent | eaf34adcbd8095bc6d1f3371b1227f654c7b19fc (diff) |
New upstream release
Diffstat (limited to 'xsd/examples/cxx/tree/messaging/dom-serialize.cxx')
-rw-r--r-- | xsd/examples/cxx/tree/messaging/dom-serialize.cxx | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/xsd/examples/cxx/tree/messaging/dom-serialize.cxx b/xsd/examples/cxx/tree/messaging/dom-serialize.cxx index c0f4311..dbf3370 100644 --- a/xsd/examples/cxx/tree/messaging/dom-serialize.cxx +++ b/xsd/examples/cxx/tree/messaging/dom-serialize.cxx @@ -1,5 +1,4 @@ // file : examples/cxx/tree/messaging/dom-serialize.cxx -// author : Boris Kolpackov <boris@codesynthesis.com> // copyright : not copyrighted - public domain #include "dom-serialize.hxx" @@ -38,8 +37,6 @@ serialize (std::ostream& os, xml::dom::ostream_format_target oft (os); -#if _XERCES_VERSION >= 30000 - // Create a DOMSerializer. // xml::dom::auto_ptr<DOMLSSerializer> writer ( @@ -55,6 +52,7 @@ serialize (std::ostream& os, // conf->setParameter (XMLUni::fgDOMWRTDiscardDefaultContent, true); conf->setParameter (XMLUni::fgDOMWRTFormatPrettyPrint, true); + conf->setParameter (XMLUni::fgDOMWRTXercesPrettyPrint, false); xml::dom::auto_ptr<DOMLSOutput> out (impl->createLSOutput ()); out->setEncoding (xml::string (encoding).c_str ()); @@ -62,28 +60,5 @@ serialize (std::ostream& os, writer->write (&doc, out.get ()); -#else - - // Create a DOMWriter. - // - xml::dom::auto_ptr<DOMWriter> writer (impl->createDOMWriter ()); - - // Set error handler. - // - writer->setErrorHandler (&ehp); - - // Set encoding. - // - writer->setEncoding(xml::string (encoding).c_str ()); - - // Set some generally nice features. - // - writer->setFeature (XMLUni::fgDOMWRTDiscardDefaultContent, true); - writer->setFeature (XMLUni::fgDOMWRTFormatPrettyPrint, true); - - writer->writeNode (&oft, doc); - -#endif - eh.throw_if_failed<tree::serialization<char> > (); } |