Hello,

I am trying to start a parser from a std::string because this is what i receive from a xml rpc channel.

The problem is that i already have tried to use DomBuilder, MemBufInputSource with and without wrappers and i can't make it. Could someone help me with this problem, like sugesting what i should properly do.
I have read all the documentation several times and i can't figure it out.


I appreciate your atention,
Best regards,
João Graça

PS: I send i little bit of code from one of my experiment so that you can see what i am trying to do.

DOMBuilder* parser = ((DOMImplementationLS*)_impl)->createDOMBuilder(DOMImplementationLS::MODE_SYNCHRONOUS, 0);

const char * msg = analysisXml.c_str();
MemBufInputSource* memBufIS = new MemBufInputSource
(
(const XMLByte*)msg
, strlen(msg)
, "repository"
, false
);
Wrapper4DOMInputSource domISWrapper(memBufIS);
// Wrapper4DOMInputSource domISWrapper(inputSource);
DOMDocument *doc = 0;
try {
doc = parser->parse(domISWrapper);
}
catch (const XMLException& toCatch) {
char* message = XMLString::transcode(toCatch.getMessage());
cout << "Exception message is: \n"
<< message << "\n";
XMLString::release(&message);
return 0;
}
///Build domain model from dom node


 return 0;

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to