Package org.cyberneko.html
Class HTMLConfiguration.ErrorReporter
java.lang.Object
org.cyberneko.html.HTMLConfiguration.ErrorReporter
- All Implemented Interfaces:
HTMLErrorReporter
- Enclosing class:
- HTMLConfiguration
Defines an error reporter for reporting HTML errors. There is no such
thing as a fatal error in parsing HTML. I/O errors are fatal but should
throw an
IOException directly instead of reporting an error.
When used in a configuration, the error reporter instance should be set as a property with the following property identifier:
"http://cyberneko.org/html/internal/error-reporter" in theComponents in the configuration can query the error reporter using this property identifier.
Note: All reported errors are within the domain "http://cyberneko.org/html".
- Author:
- Andy Clark
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ResourceBundleError messages.protected LocaleLast locale. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected org.apache.xerces.xni.parser.XMLParseExceptioncreateException(String key, Object[] args) Creates parse exception.formatMessage(String key, Object[] args) Format message without reporting error.protected StringformatSimpleMessage(String key, Object[] args) Format simple message.voidreportError(String key, Object[] args) Reports an error.voidreportWarning(String key, Object[] args) Reports a warning.
-
Field Details
-
fLastLocale
Last locale. -
fErrorMessages
Error messages.
-
-
Constructor Details
-
ErrorReporter
protected ErrorReporter()
-
-
Method Details
-
formatMessage
Format message without reporting error.- Specified by:
formatMessagein interfaceHTMLErrorReporter
-
reportWarning
public void reportWarning(String key, Object[] args) throws org.apache.xerces.xni.parser.XMLParseException Reports a warning.- Specified by:
reportWarningin interfaceHTMLErrorReporter- Throws:
org.apache.xerces.xni.parser.XMLParseException
-
reportError
public void reportError(String key, Object[] args) throws org.apache.xerces.xni.parser.XMLParseException Reports an error.- Specified by:
reportErrorin interfaceHTMLErrorReporter- Throws:
org.apache.xerces.xni.parser.XMLParseException
-
createException
Creates parse exception. -
formatSimpleMessage
Format simple message.
-