struct _xmlSchematron {
The content of this structure is not made public by the API.
} xmlSchematron;
Structure xmlSchematronParserCtxt
struct _xmlSchematronParserCtxt {
The content of this structure is not made public by the API.
} xmlSchematronParserCtxt;
Structure xmlSchematronValidCtxt
struct _xmlSchematronValidCtxt {
The content of this structure is not made public by the API.
} xmlSchematronValidCtxt;
Function type xmlSchematronValidityErrorFunc
void xmlSchematronValidityErrorFunc (void * ctx,
const char * msg,
... ...)
Signature of an error callback from a Schematron validation
| ctx: | the validation context |
| msg: | the message |
| ...: | extra arguments |
Function type xmlSchematronValidityWarningFunc
void xmlSchematronValidityWarningFunc (void * ctx,
const char * msg,
... ...)
Signature of a warning callback from a Schematron validation
| ctx: | the validation context |
| msg: | the message |
| ...: | extra arguments |
xmlSchematronFree ()
void xmlSchematronFree (xmlSchematronPtr schema)
Deallocate a Schematron structure.
| schema: | a schema structure |
xmlSchematronFreeParserCtxt ()
void xmlSchematronFreeParserCtxt (xmlSchematronParserCtxtPtr ctxt)
Free the resources associated to the schema parser context
| ctxt: | the schema parser context |
xmlSchematronFreeValidCtxt ()
void xmlSchematronFreeValidCtxt (xmlSchematronValidCtxtPtr ctxt)
Free the resources associated to the schema validation context
| ctxt: | the schema validation context |
xmlSchematronNewDocParserCtxt ()
xmlSchematronParserCtxtPtr xmlSchematronNewDocParserCtxt (xmlDocPtr doc)
Create an XML Schematrons parse context for that document. NB. The document may be modified during the parsing process.
| doc: | a preparsed document tree |
| Returns: | the parser context or NULL in case of error |
xmlSchematronNewMemParserCtxt ()
xmlSchematronParserCtxtPtr xmlSchematronNewMemParserCtxt (const char * buffer,
int size)
Create an XML Schematrons parse context for that memory buffer expected to contain an XML Schematrons file.
| buffer: | a pointer to a char array containing the schemas |
| size: | the size of the array |
| Returns: | the parser context or NULL in case of error |
xmlSchematronNewParserCtxt ()
xmlSchematronParserCtxtPtr xmlSchematronNewParserCtxt (const char * URL)
Create an XML Schematrons parse context for that file/resource expected to contain an XML Schematrons file.
| URL: | the location of the schema |
| Returns: | the parser context or NULL in case of error |
xmlSchematronParse ()
xmlSchematronPtr xmlSchematronParse (xmlSchematronParserCtxtPtr ctxt)
parse a schema definition resource and build an internal XML Shema struture which can be used to validate instances.
| ctxt: | a schema validation context |
| Returns: | the internal XML Schematron structure built from the resource or NULL in case of error |
xmlSchematronSetValidStructuredErrors ()
void xmlSchematronSetValidStructuredErrors (xmlSchematronValidCtxtPtr ctxt,
xmlStructuredErrorFunc serror,
void * ctx)
Set the structured error callback
| ctxt: | a Schematron validation context |
| serror: | the structured error function |
| ctx: | the functions context |
xmlSchematronValidateDoc ()
int xmlSchematronValidateDoc (xmlSchematronValidCtxtPtr ctxt,
xmlDocPtr instance)
Validate a tree instance against the schematron
| ctxt: | the schema validation context |
| instance: | the document instace tree |
| Returns: | 0 in case of success, -1 in case of internal error and an error count otherwise. |