Class SAXParser

  • All Implemented Interfaces:
    Parser

    public class SAXParser
    extends Object
    implements Parser
    SAXParser implements the SAX Parser interface. It is the frontend to SAX for the NanoXML parser.
    Version:
    $Name: RELEASE_2_2_1 $, $Revision: 1.5 $
    Author:
    Marc De Scheemaecker
    • Constructor Detail

      • SAXParser

        public SAXParser()
        Creates the SAX parser.
    • Method Detail

      • setLocale

        public void setLocale​(Locale locale)
                       throws SAXException
        Sets the locale. Only locales using the language english are accepted.
        Specified by:
        setLocale in interface Parser
        Parameters:
        locale - the locale
        Throws:
        SAXException - if locale is null or the associated language is not english.
      • setEntityResolver

        public void setEntityResolver​(EntityResolver resolver)
        Sets the entity resolver.
        Specified by:
        setEntityResolver in interface Parser
        Parameters:
        resolver - the entity resolver
      • setDTDHandler

        public void setDTDHandler​(DTDHandler handler)
        Sets the DTD handler. As the parser is non-validating, this handler is never called.
        Specified by:
        setDTDHandler in interface Parser
        Parameters:
        handler - the DTD handler
      • setDocumentHandler

        public void setDocumentHandler​(DocumentHandler handler)
        Allows an application to register a document event handler.
        Specified by:
        setDocumentHandler in interface Parser
        Parameters:
        handler - the document handler
      • setErrorHandler

        public void setErrorHandler​(ErrorHandler handler)
        Allow an application to register an error event handler.
        Specified by:
        setErrorHandler in interface Parser
        Parameters:
        handler - the error handler