@Override
    public void error (SAXParseException exception) throws SAXException {
        if (handler instanceof ErrorHandler) {
            ((ErrorHandler)handler).error(exception);
        } else {
            super.error(exception);
        }
    }
Handle any exceptions thrown by methods in this class. This method
provides a single place to implement custom exception handling. The
default behaviour is simply to re-throw the given exception, but
subclasses can also provide alternative ways of handling the situation.

If the wrapped handler is itself a ContentHandlerDecorator, the call
is delegated to the wrapped handler's {@link ContentHandlerDecorator#handleException(SAXException)}

@param exception the exception that was thrown
@throws SAXException the exception (if any) thrown to the client
tika-core/src/main/java/org/apache/tika/sax/ContentHandlerDecorator.java