It's a documentation bug -- use XercesDOMSupport instead of
DOMSupportDefault.
If you're going to do this, make sure you take a look at previous threads
on this topic in the archives. The most important thing is that you should
do modifications through the Xerces DOM APIs, and make sure that you
destroy the XalanDocument instance and create a new one before you try to
transform it again.
If you want to do buffer transforms, see the StreamTransform sample for
more information.
Dave
Ciprian
Ungureanu To: [EMAIL PROTECTED]
<cungurea@dyn cc: (bcc: David N Bertoni/CAM/Lotus)
asty.com> Subject: Re: XalanTransformer problem
07/02/2001
03:47 AM
Please
respond to
xalan-dev
Hi David,
I'm asking you again a question: in the documentation it is written that
you can work
with DOM input and output for the compile stylesheet. If I follow the
example like
this:
DOMParser theParser;
theParser.parse("foo.xml");
const DOM_Document theDOM = theParser.getDocument();
// Set up a XercesParserLiaison and use it to wrap the DOM_Document
// in a XalanDocument.
DOMSupportDefault theDOMSupport;
XercesParserLiaison theParserLiaison(theDOMSupport); //error
XalanDocument* theDoc = theParserLiaison.createDocument(theDOM);
// Use the XalanDocument to create an XSLTInputSource object, which
// you can then use in a transformation.
XSLTInputSource theInputSource(theDoc);
I will get an error that cannot convert parameter 1 from 'class
DOMSupportDefault' to
'class XercesDOMSupport &'
I have a strong reason why I want to parse the files into DOM tree, because
I want to
offer to the user the possibility to work with DOM tree, to change it
dynamically, to
use it as he want.
Can you tell me what is wrong with the piece of code decried and how can be
fixed to
work with DOM Input?( I want to use it with compile stylesheet. )
If isn't possible do you know a way to construct an XSLTInputSource from a
buffer(char *) ?
Thanks,
Cip