public class ParserHandler extends DefaultHandler2
Handler
objects. A handler is purshed onto the stack when a startElement event is
processed, and popped off the stack when the corresponding endElement event is processed.Modifier and Type | Class and Description |
---|---|
static interface |
ParserHandler.ContextCustomizer
Customize the context, after the configuration has set up the context before the document is
parsed.
|
Modifier and Type | Field and Description |
---|---|
protected Stack |
handlers
execution stack *
|
Constructor and Description |
---|
ParserHandler(Configuration config) |
attributeDecl, comment, elementDecl, endDTD, endEntity, externalEntityDecl, getExternalSubset, internalEntityDecl, startDTD, startEntity
fatalError, ignorableWhitespace, notationDecl, processingInstruction, setDocumentLocator, skippedEntity, unparsedEntityDecl
protected Stack handlers
public ParserHandler(Configuration config)
public void setContextCustomizer(ParserHandler.ContextCustomizer contextCustomizer)
public Configuration getConfiguration()
public void setStrict(boolean strict)
public boolean isStrict()
public boolean isValidating()
public void setValidating(boolean validating)
public void setFailOnValidationError(boolean failOnValidationError)
public boolean isFailOnValidationError()
public void setHandleMixedContent(boolean handleMixedContent)
public boolean isHandleMixedContent()
public void setForceParserDelegate(boolean forceParserDelegate)
public boolean isForceParserDelegate()
public void setRootElementType(QName rootElementType)
public QName getRootElementType()
public List getValidationErrors()
public ValidatorHandler getValidator()
public HandlerFactory getHandlerFactory()
public BindingLoader getBindingLoader()
public BindingWalker getBindingWalker()
public BindingFactory getBindingFactory()
public XSDSchema[] getSchemas()
public SchemaIndex getSchemaIndex()
public Logger getLogger()
public ParserNamespaceSupport getNamespaceSupport()
public List<URIHandler> getURIHandlers()
public void setEntityResolver(EntityResolver entityResolver)
public EntityResolver getEntityResolver()
public InputSource resolveEntity(String publicId, String systemId) throws IOException, SAXException
resolveEntity
in interface EntityResolver
resolveEntity
in class DefaultHandler2
IOException
SAXException
public InputSource resolveEntity(String name, String publicId, String baseURI, String systemId) throws SAXException, IOException
resolveEntity
in interface EntityResolver2
resolveEntity
in class DefaultHandler2
SAXException
IOException
public void startPrefixMapping(String prefix, String uri) throws SAXException
startPrefixMapping
in interface ContentHandler
startPrefixMapping
in class DefaultHandler
SAXException
public void startDocument() throws SAXException
startDocument
in interface ContentHandler
startDocument
in class DefaultHandler
SAXException
public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException
startElement
in interface ContentHandler
startElement
in class DefaultHandler
SAXException
public void characters(char[] ch, int start, int length) throws SAXException
characters
in interface ContentHandler
characters
in class DefaultHandler
SAXException
public void endElement(String uri, String localName, String qName) throws SAXException
endElement
in interface ContentHandler
endElement
in class DefaultHandler
SAXException
protected void endElementInternal(ElementHandler handler)
public void endPrefixMapping(String prefix) throws SAXException
endPrefixMapping
in interface ContentHandler
endPrefixMapping
in class DefaultHandler
SAXException
public void endDocument() throws SAXException
endDocument
in interface ContentHandler
endDocument
in class DefaultHandler
SAXException
public void warning(SAXParseException e) throws SAXException
warning
in interface ErrorHandler
warning
in class DefaultHandler
SAXException
public void error(SAXParseException e) throws SAXException
error
in interface ErrorHandler
error
in class DefaultHandler
SAXException
public Object getValue()
protected void configure(Configuration config)
protected XSDSchemaLocator[] findSchemaLocators()
protected XSDSchemaLocationResolver[] findSchemaLocationResolvers()
public void startCDATA() throws SAXException
startCDATA
in interface LexicalHandler
startCDATA
in class DefaultHandler2
SAXException
public void endCDATA() throws SAXException
endCDATA
in interface LexicalHandler
endCDATA
in class DefaultHandler2
SAXException
public boolean isCDATAEnding()
public void setCDATA(boolean b)
b
- public boolean isCDATA()
Copyright © 1996–2019 Geotools. All rights reserved.