public class BufferedDocumentContentHandler<Document extends BufferedDocument> extends DefaultHandler
BufferedDocument from the XML source stream.| Modifier and Type | Field and Description |
|---|---|
protected Document |
bufferedDocument |
static String |
CDATA_TYPE |
| Constructor and Description |
|---|
BufferedDocumentContentHandler() |
| Modifier and Type | Method and Description |
|---|---|
void |
characters(char[] ch,
int start,
int length) |
protected Document |
createDocument() |
void |
doEndElement(String uri,
String localName,
String name) |
boolean |
doStartElement(String uri,
String localName,
String name,
Attributes attributes) |
void |
endElement(String uri,
String localName,
String name) |
protected BufferedElement |
findParentElementInfo(BufferedElement elementInfo,
String name) |
protected BufferedElement |
findParentElementInfo(String name) |
protected void |
flushCharacters(String characters) |
Document |
getBufferedDocument() |
BufferedElement |
getCurrentElement() |
int |
getElementIndex() |
protected boolean |
mustEncodeCharachers() |
protected void |
printEscaped(String source,
IBufferedRegion region) |
protected void |
resetCharacters() |
void |
startDocument() |
void |
startElement(String uri,
String localName,
String name,
Attributes attributes) |
void |
startPrefixMapping(String prefix,
String uri) |
static AttributesImpl |
toAttributesImpl(Attributes attributes)
Get the SAX
AttributesImpl of teh given attributes to modify attribute values. |
endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, unparsedEntityDecl, warningpublic static final String CDATA_TYPE
protected final Document extends BufferedDocument bufferedDocument
protected Document createDocument()
public Document getBufferedDocument()
public void startDocument()
throws SAXException
startDocument in interface ContentHandlerstartDocument in class DefaultHandlerSAXExceptionpublic void startPrefixMapping(String prefix, String uri) throws SAXException
startPrefixMapping in interface ContentHandlerstartPrefixMapping in class DefaultHandlerSAXExceptionpublic final void startElement(String uri, String localName, String name, Attributes attributes) throws SAXException
startElement in interface ContentHandlerstartElement in class DefaultHandlerSAXExceptionpublic BufferedElement getCurrentElement()
protected BufferedElement findParentElementInfo(String name)
protected BufferedElement findParentElementInfo(BufferedElement elementInfo, String name)
public boolean doStartElement(String uri, String localName, String name, Attributes attributes) throws SAXException
SAXExceptionpublic final void endElement(String uri, String localName, String name) throws SAXException
endElement in interface ContentHandlerendElement in class DefaultHandlerSAXExceptionpublic void doEndElement(String uri, String localName, String name) throws SAXException
SAXExceptionpublic final void characters(char[] ch,
int start,
int length)
throws SAXException
characters in interface ContentHandlercharacters in class DefaultHandlerSAXExceptionprotected boolean mustEncodeCharachers()
protected void flushCharacters(String characters)
protected void resetCharacters()
public static AttributesImpl toAttributesImpl(Attributes attributes)
AttributesImpl of teh given attributes to modify attribute values.attributes - protected void printEscaped(String source, IBufferedRegion region)
public int getElementIndex()
Copyright © 2017. All Rights Reserved.