Basic interface for error handling
Basic interface for error handling.A client may implement this interface if it needs to provide customizable error handling support during parsing of XML documents. The ErrorHandler instance should be registered with the parser using the setErrorHandler() method of the parser object.
If an ErrorHandler is registered with a parser, the parser will report all errors during parsing by invoking the methods of this interface instead of throwing the offending exception from the parser method which initiated the error-generating operation. It is up to the application to throw any exceptions if the ErrorHandler is used. Please note that the parser is not required to provide any useful information after a call to the fatalError() method of this interface.
The HandlerBase class provides the default implementation of this interface which is to ignore warnings and non-fatal errors and throwing a SAXException for fatal errors. Applications may extend this implementation rather than implementing the whole interface itself.
The parse will invoke this method to notify the client that it has encountered a recoverable error during parsing as defined in section 1.2 of the W3C XML specification 1.0.
The parser will continue parsing after invoking this method.
The client may throw another SAXException, possibly wrapping this or a new SAXParseException.
The parse will invoke this method to notify the client that
it has encountered a recoverable error during parsing as
defined in section 1.2 of the W3C XML specification 1.0. The application shall assume that the XML content being
parsed by the parser is unusable after a call to this
method. The application may continue to collect additional
error information. If able, a parser may continue to parse
the XML document, or it may terminate parsing. The client may throw another SAXException, possibly
wrapping this or a new SAXParseException.
The parser will continue parsing after invoking this
method. The client may throw another SAXException, possibly
wrapping this or a new SAXParseException.
void fatalError(SAXParseException& exception)
void warning(SAXParseException& exception)
Alphabetic index Hierarchy of classes