com.virtuosotechnologies.lib.xml
Class ZeroToleranceErrorHandler

java.lang.Object
  extended bycom.virtuosotechnologies.lib.xml.ZeroToleranceErrorHandler
All Implemented Interfaces:
ErrorHandler

public class ZeroToleranceErrorHandler
extends Object
implements ErrorHandler

ErrorHandler that doesn't tolerate any errors. Any errors reported get thrown as exceptions. Ignores warnings. Also optionally logs events.


Constructor Summary
ZeroToleranceErrorHandler()
          Construct an error handler that doesn't log errors
ZeroToleranceErrorHandler(Level level)
          Construct an error handler that logs all errors and warnings at the given level
ZeroToleranceErrorHandler(Level errorLevel, Level warningLevel)
          Construct an error handler that logs all errors and warnings at the given levels
 
Method Summary
 void error(SAXParseException ex)
           
 void fatalError(SAXParseException ex)
           
 void warning(SAXParseException ex)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ZeroToleranceErrorHandler

public ZeroToleranceErrorHandler()
Construct an error handler that doesn't log errors


ZeroToleranceErrorHandler

public ZeroToleranceErrorHandler(Level level)
Construct an error handler that logs all errors and warnings at the given level

Parameters:
level - level to log errors and warnings

ZeroToleranceErrorHandler

public ZeroToleranceErrorHandler(Level errorLevel,
                                 Level warningLevel)
Construct an error handler that logs all errors and warnings at the given levels

Parameters:
errorLevel - level to log errors
warningLevel - level to log warnings
Method Detail

error

public void error(SAXParseException ex)
           throws SAXException
Specified by:
error in interface ErrorHandler
Throws:
SAXException

fatalError

public void fatalError(SAXParseException ex)
                throws SAXException
Specified by:
fatalError in interface ErrorHandler
Throws:
SAXException

warning

public void warning(SAXParseException ex)
             throws SAXException
Specified by:
warning in interface ErrorHandler
Throws:
SAXException