Class RepairingContentHandler

  • All Implemented Interfaces:
    org.xml.sax.ContentHandler, org.xml.sax.DTDHandler, org.xml.sax.EntityResolver, org.xml.sax.ErrorHandler, org.xml.sax.XMLFilter, org.xml.sax.XMLReader

    public class RepairingContentHandler
    extends org.xml.sax.helpers.XMLFilterImpl
    A RepairingContentHandler is a SAX filter that can be placed on the input pipeline in front of a ReceivingContentHandler for use in cases where the events supplied by the XML parser are not guaranteed to satisfy all the consistency constraints.

    In this initial implementation, all it does is to generate a startPrefixMapping call for the namespace used in an element name supplied to startElement(). This is needed when accepting input from the TagSoup HTML parser.

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void startElement​(java.lang.String uri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes atts)
      Filter a start element event.
      • Methods inherited from class org.xml.sax.helpers.XMLFilterImpl

        characters, endDocument, endElement, endPrefixMapping, error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, getProperty, ignorableWhitespace, notationDecl, parse, parse, processingInstruction, resolveEntity, setContentHandler, setDocumentLocator, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setParent, setProperty, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning
      • Methods inherited from class java.lang.Object

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

      • RepairingContentHandler

        public RepairingContentHandler()
    • Method Detail

      • startElement

        public void startElement​(java.lang.String uri,
                                 java.lang.String localName,
                                 java.lang.String qName,
                                 org.xml.sax.Attributes atts)
                          throws org.xml.sax.SAXException
        Filter a start element event.
        Specified by:
        startElement in interface org.xml.sax.ContentHandler
        Overrides:
        startElement in class org.xml.sax.helpers.XMLFilterImpl
        Parameters:
        uri - The element's Namespace URI, or the empty string.
        localName - The element's local name, or the empty string.
        qName - The element's qualified (prefixed) name, or the empty string.
        atts - The element's attributes.
        Throws:
        org.xml.sax.SAXException - The client may throw an exception during processing.