Hi Paul,
I don't have a direct answer the the question, but I can't see why it
shouldn't work in principle. Could you build xerces, xalan and your
application with debug symbols and get a stacktrace so we can see where
it went wrong? Maybe it's something simple we can get fixed.
Thanks,
Roger
On 14/08/2020 05:29, Paul Kinnucan wrote:
Hi,
Is it possible to compile a stylesheet whose source is a Xerces
DOMDocument?
In the following example, invoking compileStylesheet causes a segv:
Transformer::Transformer(DOMDocument*pSSDoc) {
XMLPlatformUtils::Initialize();
std::unique_ptr<XercesParserLiaison>
parserLiaisonPtr(newXercesParserLiaison());
std::unique_ptr<XercesDOMSupport>
xercesDOMSupportPtr(newXercesDOMSupport(*parserLiaisonPtr.get()));
XalanDocument*pXalanDoc =
parserLiaisonPtr->createDocument(pSSDoc,true,true,true);
xalanc::XalanNode*pRoot = pXalanDoc->getDocumentElement();
intres = _pXalanTransformer->compileStylesheet(pRoot, _pSS);
}
Paul