typedef struct _xmlParserInput | xmlParserInput |
typedef xmlParserInput * | xmlParserInputPtr |
xmlErrorLevel:
Indicates the level of an error
Enumerator | Value | Description |
---|---|---|
XML_ERR_NONE | 0 | |
XML_ERR_WARNING | 1 | |
XML_ERR_ERROR | 2 | |
XML_ERR_FATAL | 3 |
xmlErrorDomain:
Indicates where an error may have come from
typedef xmlError * | xmlErrorPtr |
xmlParserError:
This is an error that the XML (or HTML) parser can generate
typedef void(* | xmlGenericErrorFunc |
xmlGenericErrorFunc: Signature of the function to use when there is an error and no parsing or validity context available .
typedef void(* | xmlStructuredErrorFunc |
xmlStructuredErrorFunc: Signature of the function to use when there is an error and the module handles the new error reporting mechanism.
XMLPUBFUN void XMLCALL | xmlSetGenericErrorFunc | ( | void * | ctx, |
xmlGenericErrorFunc | handler | |||
) |
xmlSetGenericErrorFunc: Function to reset the handler and the error context for out of context error messages. This simply means that handler will be called for subsequent error messages while not parsing nor validating. And ctx will be passed as first argument to handler One can simply force messages to be emitted to another FILE * than stderr by setting ctx to this file handle and handler to NULL.
Parameters | |
---|---|
ctx | the new error handling context |
handler | the new handler function |
XMLPUBFUN void XMLCALL | initGenericErrorDefaultFunc | ( | xmlGenericErrorFunc * | handler | ) |
initGenericErrorDefaultFunc: Set or reset (if NULL) the default handler for generic errors to the builtin error function.
Parameters | |
---|---|
handler | the handler |
XMLPUBFUN void XMLCALL | xmlSetStructuredErrorFunc | ( | void * | ctx, |
xmlStructuredErrorFunc | handler | |||
) |
xmlSetStructuredErrorFunc: Function to reset the handler and the error context for out of context structured error messages. This simply means that handler will be called for subsequent error messages while not parsing nor validating. And ctx will be passed as first argument to handler
Parameters | |
---|---|
ctx | the new error handling context |
handler | the new handler function |
XMLPUBFUN void XMLCALL | xmlParserError | ( | void * | ctx, |
const char * | msg, | |||
... | ||||
) |
xmlParserError: Display and format an error messages, gives file, line, position and extra parameters.
Parameters | |
---|---|
ctx | an XML parser context |
msg | the message to display/transmit |
extra parameters for the message display |
XMLPUBFUN void XMLCALL | xmlParserWarning | ( | void * | ctx, |
const char * | msg, | |||
... | ||||
) |
xmlParserWarning: Display and format a warning messages, gives file, line, position and extra parameters.
Parameters | |
---|---|
ctx | an XML parser context |
msg | the message to display/transmit |
extra parameters for the message display |
XMLPUBFUN void XMLCALL | xmlParserValidityError | ( | void * | ctx, |
const char * | msg, | |||
... | ||||
) |
xmlParserValidityError: Display and format an validity error messages, gives file, line, position and extra parameters.
Parameters | |
---|---|
ctx | an XML parser context |
msg | the message to display/transmit |
extra parameters for the message display |
XMLPUBFUN void XMLCALL | xmlParserValidityWarning | ( | void * | ctx, |
const char * | msg, | |||
... | ||||
) |
xmlParserValidityWarning: Display and format a validity warning messages, gives file, line, position and extra parameters.
Parameters | |
---|---|
ctx | an XML parser context |
msg | the message to display/transmit |
extra parameters for the message display |
XMLPUBFUN void XMLCALL | xmlParserPrintFileInfo | ( | xmlParserInputPtr | input | ) |
xmlParserPrintFileInfo: Displays the associated file and line informations for the current input
Parameters | |
---|---|
input | an xmlParserInputPtr input |
XMLPUBFUN void XMLCALL | xmlParserPrintFileContext | ( | xmlParserInputPtr | input | ) |
xmlParserPrintFileContext: Displays current context within the input content for error tracking
Parameters | |
---|---|
input | an xmlParserInputPtr input |
XMLPUBFUN xmlErrorPtr XMLCALL | xmlGetLastError | ( | void | ) |
xmlGetLastError:
Get the last global error registered. This is per thread if compiled with thread support.
Returns NULL if no error occured or a pointer to the error
XMLPUBFUN void XMLCALL | xmlResetLastError | ( | void | ) |
xmlResetLastError:
Cleanup the last global error registered. For parsing error this does not change the well-formedness result.
OOM: never
XMLPUBFUN xmlErrorPtr XMLCALL | xmlCtxtGetLastError | ( | void * | ctx | ) |
xmlCtxtGetLastError: Get the last parsing error registered.
Returns NULL if no error occured or a pointer to the error
Parameters | |
---|---|
ctx | an XML parser context |
XMLPUBFUN void XMLCALL | xmlCtxtResetLastError | ( | void * | ctx | ) |
xmlCtxtResetLastError: Cleanup the last global error registered. For parsing error this does not change the well-formedness result.
Parameters | |
---|---|
ctx | an XML parser context |
XMLPUBFUN void XMLCALL | xmlResetError | ( | xmlErrorPtr | err | ) |
xmlResetError: Cleanup the error.
OOM: never
Parameters | |
---|---|
err | pointer to the error. |
XMLPUBFUN int XMLCALL | xmlCopyError | ( | xmlErrorPtr | from, |
xmlErrorPtr | to | |||
) |
xmlCopyError: Save the original error to the new place.
Returns 0 in case of success and -1 in case of error.
Parameters | |
---|---|
from | a source error |
to | a target error |