Re: [xml] accessing Parser-Ctxt in SAX based schema validation

On Wed, Apr 09, 2008 at 09:49:30AM +0200, Holger Kaelberer wrote:

Is there an equiv. when using xmlSchemaValidateStream or any other way 
to access the parser ctxt of the parsed file?:

state->ctxt = ...;
ret = xmlSchemaValidateStream(vctxt, buf, XML_CHAR_ENCODING_NONE,
    (xmlSAXHandlerPtr) parser_handler, state);

Can someone help me with that?

  Did you check within a debugger ? That ought to be possible i think.

One more thing concerning the SAX-Version: I was not able to do a 
validation with a SAX1-handler. 
According to xmlschemas.c xmlSchemaValidateStream presupposes a SAX2-handler: 

  yes XSD streaming validation uses a SAX2 element start callback internally
see xmlSchemaSAXHandleStartElementNs in xmlschemas.c


Red Hat Virtualization group
Daniel Veillard      | virtualization library
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]