public class ProxyContentHandler
extends org.xml.sax.helpers.DefaultHandler
As a convenience this class inherits the DefaultHandler
class
instead of just the ContentHandler
interface. This makes it
possible to use this class as an adapter when using methods like
SAXParser.parse(String, DefaultHandler)
that
expect a DefaultHandler instance instead of a ContentHandler.
Constructor and Description |
---|
ProxyContentHandler(org.xml.sax.ContentHandler handler)
Creates a proxy for the given content handler.
|
Modifier and Type | Method and Description |
---|---|
void |
characters(char[] ch,
int start,
int length)
Delegated to
handler . |
void |
endDocument()
Delegated to
handler . |
void |
endElement(java.lang.String namespaceURI,
java.lang.String localName,
java.lang.String qName)
Delegated to
handler . |
void |
endPrefixMapping(java.lang.String prefix)
Delegated to
handler . |
void |
ignorableWhitespace(char[] ch,
int start,
int length)
Delegated to
handler . |
void |
processingInstruction(java.lang.String target,
java.lang.String data)
Delegated to
handler . |
void |
setDocumentLocator(org.xml.sax.Locator locator)
Delegated to
handler . |
void |
skippedEntity(java.lang.String name)
Delegated to
handler . |
void |
startDocument()
Delegated to
handler . |
void |
startElement(java.lang.String namespaceURI,
java.lang.String localName,
java.lang.String qName,
org.xml.sax.Attributes atts)
Delegated to
handler . |
void |
startPrefixMapping(java.lang.String prefix,
java.lang.String uri)
Delegated to
handler . |
java.lang.String |
toString() |
public ProxyContentHandler(org.xml.sax.ContentHandler handler)
handler
- content handler to be proxiedpublic void characters(char[] ch, int start, int length) throws org.xml.sax.SAXException
handler
.characters
in interface org.xml.sax.ContentHandler
characters
in class org.xml.sax.helpers.DefaultHandler
ch
- passed throughstart
- passed throughlength
- passed throughorg.xml.sax.SAXException
- if an error occurspublic void endDocument() throws org.xml.sax.SAXException
handler
.endDocument
in interface org.xml.sax.ContentHandler
endDocument
in class org.xml.sax.helpers.DefaultHandler
org.xml.sax.SAXException
- if an error occurspublic void endElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName) throws org.xml.sax.SAXException
handler
.endElement
in interface org.xml.sax.ContentHandler
endElement
in class org.xml.sax.helpers.DefaultHandler
namespaceURI
- passed throughlocalName
- passed throughqName
- passed throughorg.xml.sax.SAXException
- if an error occurspublic void endPrefixMapping(java.lang.String prefix) throws org.xml.sax.SAXException
handler
.endPrefixMapping
in interface org.xml.sax.ContentHandler
endPrefixMapping
in class org.xml.sax.helpers.DefaultHandler
prefix
- passed throughorg.xml.sax.SAXException
- if an error occurspublic void ignorableWhitespace(char[] ch, int start, int length) throws org.xml.sax.SAXException
handler
.ignorableWhitespace
in interface org.xml.sax.ContentHandler
ignorableWhitespace
in class org.xml.sax.helpers.DefaultHandler
ch
- passed throughstart
- passed throughlength
- passed throughorg.xml.sax.SAXException
- if an error occurspublic void processingInstruction(java.lang.String target, java.lang.String data) throws org.xml.sax.SAXException
handler
.processingInstruction
in interface org.xml.sax.ContentHandler
processingInstruction
in class org.xml.sax.helpers.DefaultHandler
target
- passed throughdata
- passed throughorg.xml.sax.SAXException
- if an error occurspublic void setDocumentLocator(org.xml.sax.Locator locator)
handler
.setDocumentLocator
in interface org.xml.sax.ContentHandler
setDocumentLocator
in class org.xml.sax.helpers.DefaultHandler
locator
- passed throughpublic void skippedEntity(java.lang.String name) throws org.xml.sax.SAXException
handler
.skippedEntity
in interface org.xml.sax.ContentHandler
skippedEntity
in class org.xml.sax.helpers.DefaultHandler
name
- passed throughorg.xml.sax.SAXException
- if an error occurspublic void startDocument() throws org.xml.sax.SAXException
handler
.startDocument
in interface org.xml.sax.ContentHandler
startDocument
in class org.xml.sax.helpers.DefaultHandler
org.xml.sax.SAXException
- if an error occurspublic void startElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes atts) throws org.xml.sax.SAXException
handler
.startElement
in interface org.xml.sax.ContentHandler
startElement
in class org.xml.sax.helpers.DefaultHandler
namespaceURI
- passed throughlocalName
- passed throughqName
- passed throughatts
- passed throughorg.xml.sax.SAXException
- if an error occurspublic void startPrefixMapping(java.lang.String prefix, java.lang.String uri) throws org.xml.sax.SAXException
handler
.startPrefixMapping
in interface org.xml.sax.ContentHandler
startPrefixMapping
in class org.xml.sax.helpers.DefaultHandler
prefix
- passed throughuri
- passed throughorg.xml.sax.SAXException
- if an error occurspublic java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2010 - 2020 Adobe. All Rights Reserved