org.apache.cayenne.configuration

## Class SAXNestedTagHandler

- java.lang.Object
- - org.xml.sax.helpers.DefaultHandler
  - - org.apache.cayenne.configuration.SAXNestedTagHandler

- All Implemented Interfaces:
    ContentHandler, DTDHandler, EntityResolver, ErrorHandler

      public class SAXNestedTagHandler
      extends org.xml.sax.helpers.DefaultHandler

  A superclass of nested tag handlers for parsing of XML documents with SAX.
  Since:
    3.1

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected Locator` | `locator`
    `protected ContentHandler` | `parentHandler`
    `protected XMLReader` | `parser`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SAXNestedTagHandler(XMLReader parser, SAXNestedTagHandler parentHandler)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected ContentHandler` | `createChildTagHandler(String namespaceURI, String localName, String qName, Attributes attributes)`
    `void` | `endElement(String namespaceURI, String localName, String qName)`
    `void` | `setDocumentLocator(Locator locator)`
    `void` | `startElement(String namespaceURI, String localName, String qName, Attributes attributes)`
    `protected void` | `stop()`
    `protected String` | `unexpectedTagMessage(String tagFound, String... tagsExpected)`

    - ### Methods inherited from class org.xml.sax.helpers.DefaultHandler

      `characters, endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### parser

          protected XMLReader parser

    - #### parentHandler

          protected ContentHandler parentHandler

    - #### locator

          protected Locator locator

  - ### Constructor Detail

    - #### SAXNestedTagHandler

          public SAXNestedTagHandler(XMLReader parser,
                                     SAXNestedTagHandler parentHandler)

  - ### Method Detail

    - #### unexpectedTagMessage

          protected String unexpectedTagMessage(String tagFound,
                                                String... tagsExpected)

    - #### createChildTagHandler

          protected ContentHandler createChildTagHandler(String namespaceURI,
                                                         String localName,
                                                         String qName,
                                                         Attributes attributes)

    - #### stop

          protected void stop()

    - #### startElement

          public final void startElement(String namespaceURI,
                                         String localName,
                                         String qName,
                                         Attributes attributes)
                                  throws SAXException

      Specified by:
        `startElement` in interface `ContentHandler`
      Overrides:
        `startElement` in class `org.xml.sax.helpers.DefaultHandler`
      Throws:
        `SAXException`

    - #### endElement

          public void endElement(String namespaceURI,
                                 String localName,
                                 String qName)
                          throws SAXException

      Specified by:
        `endElement` in interface `ContentHandler`
      Overrides:
        `endElement` in class `org.xml.sax.helpers.DefaultHandler`
      Throws:
        `SAXException`

    - #### setDocumentLocator

          public void setDocumentLocator(Locator locator)

      Specified by:
        `setDocumentLocator` in interface `ContentHandler`
      Overrides:
        `setDocumentLocator` in class `org.xml.sax.helpers.DefaultHandler`

Copyright © 2001–2018 Apache Cayenne. All rights reserved.