Class XMLErrorHandler

  • All Implemented Interfaces:
    org.xml.sax.ErrorHandler

    public class XMLErrorHandler
    extends java.lang.Object
    implements org.xml.sax.ErrorHandler
    This class handles the errors which occur while enforcing validation against the XML Schema. Same as the VDLErrorHandler.
    Author:
    Karan Vahi, Gaurang Mehta $Revision$
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private LogManager mLogger
      The handle to the logging object that is used to log the messages.
    • Constructor Summary

      Constructors 
      Constructor Description
      XMLErrorHandler()
      The default constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void error​(org.xml.sax.SAXParseException e)
      Logs the error messages which SAX parser generates while validating the XML file against an XML Schema
      void fatalError​(org.xml.sax.SAXParseException e)
      Logs the the fatal messages which SAX parser generates while validating the XML file against an XML Schema
      void warning​(org.xml.sax.SAXParseException e)
      Logs the warning messages in the SAX parser generates while validating the XML file against an XML Schema.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • mLogger

        private LogManager mLogger
        The handle to the logging object that is used to log the messages.
    • Constructor Detail

      • XMLErrorHandler

        public XMLErrorHandler()
        The default constructor. Initializes the logger object.
    • Method Detail

      • warning

        public void warning​(org.xml.sax.SAXParseException e)
                     throws org.xml.sax.SAXException
        Logs the warning messages in the SAX parser generates while validating the XML file against an XML Schema.
        Specified by:
        warning in interface org.xml.sax.ErrorHandler
        Parameters:
        e - the execption that is being caught.
        Throws:
        org.xml.sax.SAXException
      • error

        public void error​(org.xml.sax.SAXParseException e)
                   throws org.xml.sax.SAXException
        Logs the error messages which SAX parser generates while validating the XML file against an XML Schema
        Specified by:
        error in interface org.xml.sax.ErrorHandler
        Parameters:
        e - the exception that is being caught.
        Throws:
        org.xml.sax.SAXException
      • fatalError

        public void fatalError​(org.xml.sax.SAXParseException e)
                        throws org.xml.sax.SAXException
        Logs the the fatal messages which SAX parser generates while validating the XML file against an XML Schema
        Specified by:
        fatalError in interface org.xml.sax.ErrorHandler
        Parameters:
        e - the exception that is being caught
        Throws:
        org.xml.sax.SAXException