com.ibm.xml.sax
Class NamespaceAdapter

java.lang.Object
  |
  +--com.ibm.xml.sax.NamespaceAdapter

public class NamespaceAdapter
extends java.lang.Object
implements DocumentHandler, ErrorHandler


Field Summary
protected  com.ibm.xml.sax.NamespaceAdapter.NamespaceAttributeListImpl attlist
           
protected  java.util.Stack elementStack
           
protected  ErrorHandler errorHandler
           
protected  NamespaceDocumentHandler handler
           
protected  Locator lastLocator
           
protected  Parser parser
           
 
Constructor Summary
NamespaceAdapter()
           
NamespaceAdapter(Parser parser)
           
NamespaceAdapter(java.lang.String saxParserName)
           
 
Method Summary
 void characters(char[] ch, int start, int length)
          Applications must not call this method.
 void endDocument()
          Applications must not call this method.
 void endElement(java.lang.String name)
          Applications must not call this method.
 void error(SAXParseException exception)
          Applications must not call this method.
 void fatalError(SAXParseException exception)
          Applications must not call this method.
 void ignorableWhitespace(char[] ch, int start, int length)
          Applications must not call this method.
 void parse(InputSource source)
           
 void parse(java.lang.String systemId)
           
 void processingInstruction(java.lang.String target, java.lang.String data)
          Applications must not call this method.
 java.lang.String searchForNamespace(java.lang.String prefix)
           
 void setDocumentHandler(NamespaceDocumentHandler handler)
           
 void setDocumentLocator(Locator locator)
          Applications must not call this method.
 void setDTDHandler(DTDHandler handler)
           
 void setEntityResolver(EntityResolver resolver)
           
 void setErrorHandler(ErrorHandler handler)
           
 void setLocale(java.util.Locale locale)
           
 void startDocument()
          Applications must not call this method.
 void startElement(java.lang.String name, AttributeList atts)
          Applications must not call this method.
 void warning(SAXParseException exception)
          Applications must not call this method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

handler

protected NamespaceDocumentHandler handler

errorHandler

protected ErrorHandler errorHandler

elementStack

protected java.util.Stack elementStack

attlist

protected com.ibm.xml.sax.NamespaceAdapter.NamespaceAttributeListImpl attlist

lastLocator

protected Locator lastLocator

parser

protected Parser parser
Constructor Detail

NamespaceAdapter

public NamespaceAdapter()
                 throws java.lang.ClassNotFoundException,
                        java.lang.IllegalAccessException,
                        java.lang.InstantiationException,
                        java.lang.ClassCastException
See Also:
ParserFactory.makeParser()

NamespaceAdapter

public NamespaceAdapter(java.lang.String saxParserName)
                 throws java.lang.ClassNotFoundException,
                        java.lang.IllegalAccessException,
                        java.lang.InstantiationException,
                        java.lang.ClassCastException
Parameters:
saxParserName - A class name of SAX Parser.
See Also:
ParserFactory.makeParser(java.lang.String)

NamespaceAdapter

public NamespaceAdapter(Parser parser)
Method Detail

parse

public void parse(InputSource source)
           throws SAXException,
                  java.io.IOException

parse

public void parse(java.lang.String systemId)
           throws SAXException,
                  java.io.IOException

setDocumentHandler

public void setDocumentHandler(NamespaceDocumentHandler handler)

setDTDHandler

public void setDTDHandler(DTDHandler handler)

setEntityResolver

public void setEntityResolver(EntityResolver resolver)

setErrorHandler

public void setErrorHandler(ErrorHandler handler)

setLocale

public void setLocale(java.util.Locale locale)
               throws SAXException

startElement

public void startElement(java.lang.String name,
                         AttributeList atts)
                  throws SAXException
Applications must not call this method.
Specified by:
startElement in interface DocumentHandler

endElement

public void endElement(java.lang.String name)
                throws SAXException
Applications must not call this method.
Specified by:
endElement in interface DocumentHandler

searchForNamespace

public java.lang.String searchForNamespace(java.lang.String prefix)
                                    throws SAXException
Returns:
null: No declaration for specified prefix or empty namespace

setDocumentLocator

public void setDocumentLocator(Locator locator)
Applications must not call this method.
Specified by:
setDocumentLocator in interface DocumentHandler

startDocument

public void startDocument()
                   throws SAXException
Applications must not call this method.
Specified by:
startDocument in interface DocumentHandler

endDocument

public void endDocument()
                 throws SAXException
Applications must not call this method.
Specified by:
endDocument in interface DocumentHandler

characters

public void characters(char[] ch,
                       int start,
                       int length)
                throws SAXException
Applications must not call this method.
Specified by:
characters in interface DocumentHandler

ignorableWhitespace

public void ignorableWhitespace(char[] ch,
                                int start,
                                int length)
                         throws SAXException
Applications must not call this method.
Specified by:
ignorableWhitespace in interface DocumentHandler

processingInstruction

public void processingInstruction(java.lang.String target,
                                  java.lang.String data)
                           throws SAXException
Applications must not call this method.
Specified by:
processingInstruction in interface DocumentHandler

warning

public void warning(SAXParseException exception)
             throws SAXException
Applications must not call this method.
Specified by:
warning in interface ErrorHandler

error

public void error(SAXParseException exception)
           throws SAXException
Applications must not call this method.
Specified by:
error in interface ErrorHandler

fatalError

public void fatalError(SAXParseException exception)
                throws SAXException
Applications must not call this method.
Specified by:
fatalError in interface ErrorHandler