Package org.smooks.engine.delivery
Class SmooksContentHandler
- java.lang.Object
-
- org.xml.sax.helpers.DefaultHandler
-
- org.xml.sax.ext.DefaultHandler2
-
- org.smooks.engine.delivery.SmooksContentHandler
-
- All Implemented Interfaces:
SAXEventReplay,ContentHandler,DTDHandler,EntityResolver,ErrorHandler,DeclHandler,EntityResolver2,LexicalHandler
- Direct Known Subclasses:
DOMBuilderContentHandler,SaxNgContentHandler
public abstract class SmooksContentHandler extends DefaultHandler2 implements SAXEventReplay
Abstract SAX Content Handler.- Author:
- tom.fennelly@gmail.com
-
-
Constructor Summary
Constructors Constructor Description SmooksContentHandler(ExecutionContext executionContext, SmooksContentHandler parentContentHandler)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract voidclose()voiddetachHandler()voidendElement(String uri, String localName, String qName)abstract voidendElement(EndElementEvent endEvent)ExecutionContextgetExecutionContext()static SmooksContentHandlergetHandler(ExecutionContext executionContext)NamespaceDeclarationStackgetNamespaceDeclarationStack()SmooksContentHandlergetNestedContentHandler()SmooksContentHandlergetParentContentHandler()voidreplay(ContentHandler handler)Replay the last SAX event onto the supplied SAXContentHandlerinstance.voidreplayStartElement()voidresetNestedContentHandler()voidstartElement(String uri, String localName, String qName, Attributes attributes)abstract voidstartElement(StartElementEvent startEvent)-
Methods inherited from class org.xml.sax.ext.DefaultHandler2
attributeDecl, comment, elementDecl, endCDATA, endDTD, endEntity, externalEntityDecl, getExternalSubset, internalEntityDecl, resolveEntity, resolveEntity, startCDATA, startDTD, startEntity
-
Methods inherited from class org.xml.sax.helpers.DefaultHandler
characters, endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning
-
-
-
-
Constructor Detail
-
SmooksContentHandler
public SmooksContentHandler(ExecutionContext executionContext, SmooksContentHandler parentContentHandler)
-
-
Method Detail
-
getNamespaceDeclarationStack
public NamespaceDeclarationStack getNamespaceDeclarationStack()
-
replayStartElement
public void replayStartElement()
-
startElement
public final void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException
- Specified by:
startElementin interfaceContentHandler- Overrides:
startElementin classDefaultHandler- Throws:
SAXException
-
startElement
public abstract void startElement(StartElementEvent startEvent) throws SAXException
- Throws:
SAXException
-
endElement
public final void endElement(String uri, String localName, String qName) throws SAXException
- Specified by:
endElementin interfaceContentHandler- Overrides:
endElementin classDefaultHandler- Throws:
SAXException
-
endElement
public abstract void endElement(EndElementEvent endEvent) throws SAXException
- Throws:
SAXException
-
replay
public void replay(ContentHandler handler) throws SmooksException
Description copied from interface:SAXEventReplayReplay the last SAX event onto the supplied SAXContentHandlerinstance.- Specified by:
replayin interfaceSAXEventReplay- Parameters:
handler- The handler on whic to replay the last event.- Throws:
SmooksException- Error replaying last event.
-
getHandler
public static SmooksContentHandler getHandler(ExecutionContext executionContext)
-
detachHandler
public void detachHandler()
-
getExecutionContext
public ExecutionContext getExecutionContext()
-
getParentContentHandler
public SmooksContentHandler getParentContentHandler()
-
getNestedContentHandler
public SmooksContentHandler getNestedContentHandler()
-
resetNestedContentHandler
public void resetNestedContentHandler()
-
close
public abstract void close()
-
-