Code example for ErrorHandler

Methods: error

0
	if (locator == null)
	    err = new SAXParseException (description, null, null, -1, -1);
	else 
	    err = new SAXParseException (description, locator);
	if (errHandler != null)
	    errHandler.error (err);
	else	// else we always treat it as fatal! 
	    throw err;
    } 
 
    private void fatalError (String description)
    throws SAXException 
    { 
	ErrorHandler		errHandler = getErrorHandler ();
	Locator			locator = getDocumentLocator ();
	SAXParseException	err;
 
	if (locator != null)
	    err = new SAXParseException (description, locator);
	else 
	    err = new SAXParseException (description, null, null, -1, -1);