com.sun.xml.bind.v2.runtime.unmarshaller
Class SAXConnector

java.lang.Object
  extended by com.sun.xml.bind.v2.runtime.unmarshaller.SAXConnector
All Implemented Interfaces:
UnmarshallerHandler, ContentHandler

public final class SAXConnector
extends Object
implements UnmarshallerHandler

Receives SAX events and convert them to our internal events.


Constructor Summary
SAXConnector(XmlVisitor next, LocatorEx externalLocator)
           
 
Method Summary
 void characters(char[] buf, int start, int len)
           
 void endDocument()
           
 void endElement(String uri, String localName, String qName)
           
 void endPrefixMapping(String prefix)
           
 UnmarshallingContext getContext()
           
 Object getResult()
           
 void ignorableWhitespace(char[] buf, int start, int len)
           
 void processingInstruction(String target, String data)
           
 void setDocumentLocator(Locator locator)
           
 void skippedEntity(String name)
           
 void startDocument()
           
 void startElement(String uri, String local, String qname, Attributes atts)
           
 void startPrefixMapping(String prefix, String uri)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SAXConnector

public SAXConnector(XmlVisitor next,
                    LocatorEx externalLocator)
Parameters:
externalLocator - If the caller is producing SAX events from sources other than Unicode and angle brackets, the caller can override the default SAX Locator object by this object to provide better location information.
Method Detail

getResult

public Object getResult()
                 throws JAXBException,
                        IllegalStateException
Specified by:
getResult in interface UnmarshallerHandler
Throws:
JAXBException
IllegalStateException

getContext

public UnmarshallingContext getContext()

setDocumentLocator

public void setDocumentLocator(Locator locator)
Specified by:
setDocumentLocator in interface ContentHandler

startDocument

public void startDocument()
                   throws SAXException
Specified by:
startDocument in interface ContentHandler
Throws:
SAXException

endDocument

public void endDocument()
                 throws SAXException
Specified by:
endDocument in interface ContentHandler
Throws:
SAXException

startPrefixMapping

public void startPrefixMapping(String prefix,
                               String uri)
                        throws SAXException
Specified by:
startPrefixMapping in interface ContentHandler
Throws:
SAXException

endPrefixMapping

public void endPrefixMapping(String prefix)
                      throws SAXException
Specified by:
endPrefixMapping in interface ContentHandler
Throws:
SAXException

startElement

public void startElement(String uri,
                         String local,
                         String qname,
                         Attributes atts)
                  throws SAXException
Specified by:
startElement in interface ContentHandler
Throws:
SAXException

endElement

public void endElement(String uri,
                       String localName,
                       String qName)
                throws SAXException
Specified by:
endElement in interface ContentHandler
Throws:
SAXException

characters

public final void characters(char[] buf,
                             int start,
                             int len)
Specified by:
characters in interface ContentHandler

ignorableWhitespace

public final void ignorableWhitespace(char[] buf,
                                      int start,
                                      int len)
Specified by:
ignorableWhitespace in interface ContentHandler

processingInstruction

public void processingInstruction(String target,
                                  String data)
Specified by:
processingInstruction in interface ContentHandler

skippedEntity

public void skippedEntity(String name)
Specified by:
skippedEntity in interface ContentHandler