Overview | Package | Class | Tree | Deprecated | Index | Help
| Oracle® Application Server XML Java API Reference 10g Release 2 (10.1.2) Part no. B12024-03 September 2004
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.xml.parser.v2
Class DefaultXMLDocumentHandler

    java.lang.Object
      |
      +--org.xml.sax.HandlerBase
            |
            +--oracle.xml.parser.v2.DefaultXMLDocumentHandler

All Implemented Interfaces:
  DocumentHandler, DTDHandler, EntityResolver, ErrorHandler, XMLDocumentHandler

Direct Known Subclasses:
  CXMLHandlerBase, DocumentBuilder, XMLTokenizer

public class DefaultXMLDocumentHandler
extends HandlerBase
implements XMLDocumentHandler

This class implements the default behaviour for the `XMLDocumentHandler` interface.

Application writers can extend this class when they need to implement only part of the interface

Constructor Summary
`DefaultXMLDocumentHandler()` Constructs a default document handler

Method Summary
`void` | `cDATASection(char[] ch, int start, int length)` Receive notification of a CDATA Section.
`void` | `comment(java.lang.String data)` Receive notification of a comment.
`void` | `endDoctype()` Receive notification of end of the DTD.
`void` | `endElement(NSName elem)` Receive notification of the end of an element.
`void` | `endElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName)` Receive notification of the end of an element.
`void` | `endPrefixMapping(java.lang.String prefix)` End the scope of a prefix-URI mapping.
`XMLDocumentHandler` | `getHandler()` Get the next pipe-line node handler.
`void` | `setDoctype(DTD dtd)` Receive notification of DTD.
`void` | `setError(XMLError he)` Receive notification of a XMLError handler.
`void` | `setHandler(XMLDocumentHandler h)` Receive notification of a next pipe-line node handler.
`void` | `setTextDecl(java.lang.String version, java.lang.String encoding)` Receive notification of a Text XML Declaration.
`void` | `setXMLDecl(java.lang.String version, java.lang.String standalone, java.lang.String encoding)` Receive notification of an XML Declaration.
`void` | `setXMLSchema(java.lang.Object s)` Receive notification of a XMLSchema object.
`void` | `skippedEntity(java.lang.String name)` Receive notification of a skipped entity.
`void` | `startElement(NSName elem, SAXAttrList attrlist)` Receive notification of the beginning of an element.
`void` | `startElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName, Attributes atts)` Receive notification of the beginning of an element.
`void` | `startPrefixMapping(java.lang.String prefix, java.lang.String uri)` Begin the scope of a prefix-URI Namespace mapping.

Methods inherited from class org.xml.sax.HandlerBase
`characters, endDocument, endElement, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, startDocument, startElement, unparsedEntityDecl, warning`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.xml.sax.DocumentHandler
`characters, endDocument, endElement, ignorableWhitespace, processingInstruction, setDocumentLocator, startDocument, startElement`

Constructor Detail

### DefaultXMLDocumentHandler

    public DefaultXMLDocumentHandler()

  Constructs a default document handler

Method Detail

### startElement

    public void startElement(NSName elem,
    SAXAttrList attrlist)
                      throws SAXException

  Receive notification of the beginning of an element.
  Specified by:
    `startElement` in interface `XMLDocumentHandler`
  Parameters:
    `elem` - NSName object
    `attrlist` - SAXAttrList for the element
  Throws:
    `SAXException` - A `SAXException` could be thrown.
  See Also:
    `DocumentHandler.startElement(java.lang.String, org.xml.sax.AttributeList)`

### startElement

    public void startElement(java.lang.String namespaceURI,
                             java.lang.String localName,
                             java.lang.String qName,
    Attributes atts)
                      throws SAXException

  Receive notification of the beginning of an element.
  Parameters:
    `localName` - The local name (without prefix), or the empty string if Namespace processing is not being performed.
    `qName` - The qualified name (with prefix), or the empty string if qualified names are not available.
    `atts` - The attributes attached to the element. If there are no attributes, it shall be an empty Attributes object.
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.
  See Also:
    `endElement(oracle.xml.parser.v2.NSName)`, `Attributes`

### endElement

    public void endElement(NSName elem)
                    throws SAXException

  Receive notification of the end of an element.
  Specified by:
    `endElement` in interface `XMLDocumentHandler`
  Parameters:
    `elem` - NSName object
  Throws:
    `SAXException` - A `SAXException` could be thrown.
  See Also:
    `DocumentHandler.endElement(java.lang.String)`

### endElement

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

  Receive notification of the end of an element.
  Parameters:
    `localName` - The local name (without prefix), or the empty string if Namespace processing is not being performed.
    `qName` - The qualified XML 1.0 name (with prefix), or the empty string if qualified names are not available.
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### setDoctype

    public void setDoctype(DTD dtd)
                    throws SAXException

  Receive notification of DTD. Sets the DTD
  Specified by:
    `setDoctype` in interface `XMLDocumentHandler`
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### endDoctype

    public void endDoctype()
                    throws SAXException

  Receive notification of end of the DTD.
  Specified by:
    `endDoctype` in interface `XMLDocumentHandler`
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### setXMLDecl

    public void setXMLDecl(java.lang.String version,
                           java.lang.String standalone,
                           java.lang.String encoding)
                    throws SAXException

  Receive notification of an XML Declaration.

  The Parser will invoke this method once for XML Decl

  Specified by:
    `setXMLDecl` in interface `XMLDocumentHandler`
  Parameters:
    `version` - The version number
    `standalone` - The standalone value (or null, if not specifed)
    `encoding` - The encoding name (or null, if not specifed)
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### setTextDecl

    public void setTextDecl(java.lang.String version,
                            java.lang.String encoding)
                     throws SAXException

  Receive notification of a Text XML Declaration.

  The Parser will invoke this method once for each text XML Decl

  Specified by:
    `setTextDecl` in interface `XMLDocumentHandler`
  Parameters:
    `version` - The version number (or null, if not specified)
    `encoding` - The encoding name
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### comment

    public void comment(java.lang.String data)
                 throws SAXException

  Receive notification of a comment.

  The Parser will invoke this method once for each comment found: note that comment may occur before or after the main document element.

  Specified by:
    `comment` in interface `XMLDocumentHandler`
  Parameters:
    `data` - The comment data, or null if none was supplied.
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### cDATASection

    public void cDATASection(char[] ch,
                             int start,
                             int length)
                      throws SAXException

  Receive notification of a CDATA Section.

  The Parser will invoke this method once for each CDATA Section found.

  Specified by:
    `cDATASection` in interface `XMLDocumentHandler`
  Parameters:
    `ch` - The CDATA section characters.
    `start` - The start position in the character array.
    `length` - The number of characters to use from the character array.
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### setHandler

    public void setHandler(XMLDocumentHandler h)
                    throws SAXException

  Receive notification of a next pipe-line node handler.
  Specified by:
    `setHandler` in interface `XMLDocumentHandler`
  Parameters:
    `h` - The XMLDocumentHandler node
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### getHandler

    public XMLDocumentHandler getHandler()

  Get the next pipe-line node handler.
  Specified by:
    `getHandler` in interface `XMLDocumentHandler`
  Returns:
    The XMLDocumentHandler node

### setError

    public void setError(XMLError he)
                  throws SAXException

  Receive notification of a XMLError handler.
  Specified by:
    `setError` in interface `XMLDocumentHandler`
  Parameters:
    `he` - The XMLError object
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### setXMLSchema

    public void setXMLSchema(java.lang.Object s)
                      throws SAXException

  Receive notification of a XMLSchema object.
  Specified by:
    `setXMLSchema` in interface `XMLDocumentHandler`
  Parameters:
    `s` - The XMLSchema object
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

### startPrefixMapping

    public void startPrefixMapping(java.lang.String prefix,
                                   java.lang.String uri)
                            throws SAXException

  Begin the scope of a prefix-URI Namespace mapping.
  Parameters:
    `prefix` - The Namespace prefix being declared.
    `uri` - The Namespace URI the prefix is mapped to.
  Throws:
    `SAXException` - The client may throw an exception during processing.
  See Also:
    `endPrefixMapping(java.lang.String)`, `startElement(oracle.xml.parser.v2.NSName, oracle.xml.parser.v2.SAXAttrList)`

### endPrefixMapping

    public void endPrefixMapping(java.lang.String prefix)
                          throws SAXException

  End the scope of a prefix-URI mapping.
  Parameters:
    `prefix` - The prefix that was being mapping.
  Throws:
    `SAXException` - The client may throw an exception during processing.
  See Also:
    `startPrefixMapping(java.lang.String, java.lang.String)`, `endElement(oracle.xml.parser.v2.NSName)`

### skippedEntity

    public void skippedEntity(java.lang.String name)
                       throws SAXException

  Receive notification of a skipped entity.
  Parameters:
    `name` - The name of the skipped entity. If it is a parameter entity, the name will begin with '%', and if it is the external DTD subset, it will be the string "[dtd]".
  Throws:
    `SAXException` - Any SAX exception, possibly wrapping another exception.

Overview | Package | Class | Tree | Deprecated | Index | Help
| Oracle® Application Server XML Java API Reference 10g Release 2 (10.1.2) Part no. B12024-03 September 2004
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003, 2004, Oracle. All rights reserved.