?
Solved

How do I write a DOM Document into a istream?

Posted on 2008-10-23
2
Medium Priority
?
999 Views
Last Modified: 2013-11-13
I would like to know how to write a Xerces DOM Document tree into a istream type.(preferably with an example).

 I will later need to pass this stream for XSLT transformation (in xalan).

ps: second sentence is only for your better understanding of the situation
0
Comment
Question by:Cool-Guy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 3

Accepted Solution

by:
romanm earned 1500 total points
ID: 22844815
In general, I would create two objects,
1. A file handler that implements the IStream
2. A MyXMLWriter class that implements XMLFormatTarget and writes into an IStream object.

You create a MyXMLWriter object, set the file handler as its IStream,
Use the serializing sample to handle the writing to the MyXMLWriter object (see samples from links below)

here is some help
http://www.w3.org/TR/2004/REC-DOM-Level-3-LS-20040407/load-save.html

and look for DOMLSSerializer in the following:
http://xerces.apache.org/xerces-c/program-dom-3.html#XercesDOMFeatures

my 2 cents
0
 

Author Closing Comment

by:Cool-Guy
ID: 31509196
Thanks
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
This article will inform Clients about common and important expectations from the freelancers (Experts) who are looking at your Gig.
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question