Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   XML (http://www.velocityreviews.com/forums/f32-xml.html)
-   -   Xerces output stream (http://www.velocityreviews.com/forums/t169256-xerces-output-stream.html)

shaun 05-03-2005 09:55 AM

Xerces output stream
 
Xerces-C++ appears to have different methods for 1) Output to file and
2)Output to screen, namely (cut and paste from code):

LocalFileFormatTarget target(X(fileName.c_str()));
pWriter->setEncoding(X("UTF-8"));
pWriter->writeNode(&target, *m_pDoc);



XMLFormatTarget * pTarget=new StdOutFormatTarget();
pSerializer->setNewLine(X("\n"));
//fflush(stdout);
pTarget->flush();
pSerializer->writeNode(pTarget,*m_pDoc);
delete pTarget;



Is there some way of just giving it an ostream (cout, file or
ostreamstring) object and telling it to stream the nodes as text into
that object?

cheers

shaun


All times are GMT. The time now is 04:58 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.