com.sun.xml.bind.unmarshaller
Class InterningXMLReader
java.lang.Object
org.xml.sax.helpers.XMLFilterImpl
com.sun.xml.bind.unmarshaller.InterningXMLReader
- All Implemented Interfaces:
- ContentHandler, DTDHandler, EntityResolver, ErrorHandler, XMLFilter, XMLReader
public class InterningXMLReader
- extends XMLFilterImpl
XMLReader that interns all the string constants before
calling the ContentHandler.
Most of the parsers out there (at least Crimson and Xerces) supports
SAX http://xml.org/sax/features/string-interning feature,
but if the parser doesn't support it (or if the SAX events is read
from components other than XMLReader, this adaptor is used
to make all strings interned.
- Since:
- JAXB RI 1.0.3
- Author:
- Kohsuke Kawaguchi (kohsuke.kawaguchi@sun.com)
| Methods inherited from class org.xml.sax.helpers.XMLFilterImpl |
characters, endDocument, error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, getProperty, ignorableWhitespace, notationDecl, parse, parse, resolveEntity, setContentHandler, setDocumentLocator, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setParent, setProperty, skippedEntity, startDocument, unparsedEntityDecl, warning |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
InterningXMLReader
protected InterningXMLReader(XMLReader core)
InterningXMLReader
protected InterningXMLReader()
adapt
public static XMLReader adapt(XMLReader reader)
- Wraps the given
XMLReader (if necessary) so that
it performs string interning.
endElement
public void endElement(String uri,
String localName,
String qName)
throws SAXException
- Specified by:
endElement in interface ContentHandler- Overrides:
endElement in class XMLFilterImpl
- Throws:
SAXException
endPrefixMapping
public void endPrefixMapping(String prefix)
throws SAXException
- Specified by:
endPrefixMapping in interface ContentHandler- Overrides:
endPrefixMapping in class XMLFilterImpl
- Throws:
SAXException
processingInstruction
public void processingInstruction(String target,
String data)
throws SAXException
- Specified by:
processingInstruction in interface ContentHandler- Overrides:
processingInstruction in class XMLFilterImpl
- Throws:
SAXException
startElement
public void startElement(String uri,
String localName,
String qName,
Attributes atts)
throws SAXException
- Specified by:
startElement in interface ContentHandler- Overrides:
startElement in class XMLFilterImpl
- Throws:
SAXException
startPrefixMapping
public void startPrefixMapping(String prefix,
String uri)
throws SAXException
- Specified by:
startPrefixMapping in interface ContentHandler- Overrides:
startPrefixMapping in class XMLFilterImpl
- Throws:
SAXException
Copyright © 2005-2011 Oracle Corporation. All Rights Reserved.