public class MicroSAXHandler extends Object implements EntityResolver2, DTDHandler, ContentHandler, ErrorHandler, LexicalHandler
MicroReader.| Constructor and Description |
|---|
MicroSAXHandler(boolean bSaveIgnorableWhitespaces,
EntityResolver aEntityResolver,
boolean bTrackPosition) |
| Modifier and Type | Method and Description |
|---|---|
void |
characters(char[] aChars,
int nStart,
int nLength) |
void |
comment(char[] aChars,
int nStart,
int nLength) |
void |
endCDATA() |
void |
endDocument() |
void |
endDTD() |
void |
endElement(String sNamespaceURI,
String sLocalName,
String sQName) |
void |
endEntity(String sName) |
void |
endPrefixMapping(String sPrefix) |
void |
error(SAXParseException ex) |
void |
fatalError(SAXParseException ex) |
IMicroDocument |
getDocument() |
InputSource |
getExternalSubset(String sName,
String sBaseURI) |
String |
getSourceXMLEncoding() |
String |
getSourceXMLVersion() |
void |
ignorableWhitespace(char[] aChars,
int nStart,
int nLength) |
void |
notationDecl(String sName,
String sPublicId,
String sSystemId) |
void |
processingInstruction(String sTarget,
String sData) |
InputSource |
resolveEntity(String sPublicId,
String sSystemId) |
InputSource |
resolveEntity(String sName,
String sPublicId,
String sBaseURI,
String sSystemId) |
void |
setDocumentLocator(Locator aLocator) |
void |
skippedEntity(String sName) |
void |
startCDATA() |
void |
startDocument() |
void |
startDTD(String sName,
String sPublicId,
String sSystemId) |
void |
startElement(String sNamespaceURI,
String sLocalName,
String sQName,
Attributes aAttributes) |
void |
startEntity(String sName) |
void |
startPrefixMapping(String sPrefix,
String sNamespaceURI) |
void |
unparsedEntityDecl(String sName,
String sPublicId,
String sSystemId,
String sNotationName) |
void |
warning(SAXParseException ex) |
public MicroSAXHandler(boolean bSaveIgnorableWhitespaces,
@Nullable
EntityResolver aEntityResolver,
boolean bTrackPosition)
public void setDocumentLocator(@Nullable Locator aLocator)
setDocumentLocator in interface ContentHandlerpublic void startDocument()
startDocument in interface ContentHandlerpublic void endDocument()
endDocument in interface ContentHandlerpublic void startDTD(String sName, String sPublicId, String sSystemId) throws SAXException
startDTD in interface LexicalHandlerSAXExceptionpublic void endDTD()
throws SAXException
endDTD in interface LexicalHandlerSAXExceptionpublic void startElement(@Nullable String sNamespaceURI, @Nonnull String sLocalName, @Nullable String sQName, @Nullable Attributes aAttributes)
startElement in interface ContentHandlerpublic void endElement(String sNamespaceURI, String sLocalName, String sQName)
endElement in interface ContentHandlerpublic void processingInstruction(String sTarget, String sData)
processingInstruction in interface ContentHandlerpublic void characters(@Nonnull char[] aChars, @Nonnegative int nStart, @Nonnegative int nLength)
characters in interface ContentHandlerpublic void comment(@Nonnull char[] aChars, @Nonnegative int nStart, @Nonnegative int nLength) throws SAXException
comment in interface LexicalHandlerSAXExceptionpublic void ignorableWhitespace(@Nonnull char[] aChars, @Nonnegative int nStart, @Nonnegative int nLength)
ignorableWhitespace in interface ContentHandler@Nullable public InputSource resolveEntity(String sPublicId, String sSystemId) throws IOException, SAXException
resolveEntity in interface EntityResolverIOExceptionSAXException@Nullable public InputSource getExternalSubset(String sName, @Nullable String sBaseURI) throws SAXException, IOException
getExternalSubset in interface EntityResolver2SAXExceptionIOException@Nullable public InputSource resolveEntity(@Nullable String sName, @Nullable String sPublicId, @Nullable String sBaseURI, @Nonnull String sSystemId) throws SAXException, IOException
resolveEntity in interface EntityResolver2SAXExceptionIOExceptionpublic void unparsedEntityDecl(String sName, String sPublicId, String sSystemId, String sNotationName)
unparsedEntityDecl in interface DTDHandlerpublic void notationDecl(String sName, String sPublicId, String sSystemId) throws SAXException
notationDecl in interface DTDHandlerSAXExceptionpublic void skippedEntity(String sName)
skippedEntity in interface ContentHandlerpublic void startEntity(String sName) throws SAXException
startEntity in interface LexicalHandlerSAXExceptionpublic void endEntity(String sName) throws SAXException
endEntity in interface LexicalHandlerSAXExceptionpublic void startCDATA()
throws SAXException
startCDATA in interface LexicalHandlerSAXExceptionpublic void endCDATA()
throws SAXException
endCDATA in interface LexicalHandlerSAXExceptionpublic void startPrefixMapping(@Nonnull String sPrefix, @Nonnull String sNamespaceURI) throws SAXException
startPrefixMapping in interface ContentHandlerSAXExceptionpublic void endPrefixMapping(@Nonnull String sPrefix) throws SAXException
endPrefixMapping in interface ContentHandlerSAXExceptionpublic void warning(SAXParseException ex)
warning in interface ErrorHandlerpublic void error(SAXParseException ex)
error in interface ErrorHandlerpublic void fatalError(SAXParseException ex)
fatalError in interface ErrorHandler@Nullable public IMicroDocument getDocument()
null if
no document start event came in.@Nullable public String getSourceXMLVersion()
null.Copyright © 2014–2021 Philip Helger. All rights reserved.