public class AbstractParser extends Object
Modifier and Type | Field and Description |
---|---|
static String |
FEATURE_OFF |
static String |
FEATURE_ON |
static String |
ORG_XML_SAX_DRIVER |
Constructor and Description |
---|
AbstractParser(ExecutionContext execContext) |
AbstractParser(ExecutionContext execContext,
SmooksResourceConfiguration saxDriverConfig)
Public constructor.
|
public static final String ORG_XML_SAX_DRIVER
public static final String FEATURE_ON
public static final String FEATURE_OFF
public AbstractParser(ExecutionContext execContext, SmooksResourceConfiguration saxDriverConfig)
execContext
- The Smooks Container Request that the parser is being instantiated on behalf of.saxDriverConfig
- SAX Parser configuration. See .cdrl Configuration.public AbstractParser(ExecutionContext execContext)
protected ExecutionContext getExecContext()
protected SmooksResourceConfiguration getSaxDriverConfig()
public static void attachXMLReader(XMLReader xmlReader, ExecutionContext execContext)
public static XMLReader getXMLReader(ExecutionContext execContext)
public static void detachXMLReader(ExecutionContext execContext)
public static Stack<XMLReader> getReaders(ExecutionContext execContext)
public static void setReaders(Stack<XMLReader> readers, ExecutionContext execContext)
public static SmooksResourceConfiguration getSAXParserConfiguration(ContentDeliveryConfig deliveryConfig)
deliveryConfig
- Content delivery configuration.protected InputSource createInputSource(Source source, String contentEncoding)
protected InputStream getInputStream(StreamSource streamSource)
protected Writer getWriter(Result result, ExecutionContext executionContext)
protected XMLReader createXMLReader() throws SAXException
SAXException
protected void attachNamespaceDeclarationStack(XMLReader reader, ExecutionContext execContext)
protected void configureReader(XMLReader reader, DefaultHandler2 handler, ExecutionContext execContext, Source source) throws SAXException
SAXException
public static boolean isFeatureOn(String name, SmooksResourceConfiguration saxDriverConfig) throws SAXException
SAXException
public static boolean isFeatureOff(String name, SmooksResourceConfiguration saxDriverConfig) throws SAXException
SAXException
Copyright © 2020. All rights reserved.