public class DOMParser extends AbstractParser
SmooksXMLReader
, the configuration will be
passed to the parser via ConfigParam
annotaions on config properties
defined on the implementation.
<smooks-resource selector="org.xml.sax.driver" path="org.milyn.protocolx.XParser" > <!-- Optional list of driver parameters forSmooksXMLReader
implementations. SeeSmooksResourceConfiguration
for how to add configuration parameters. --> </smooks-resource>
FEATURE_OFF, FEATURE_ON, ORG_XML_SAX_DRIVER
Constructor and Description |
---|
DOMParser(ExecutionContext execContext)
Public constructor.
|
DOMParser(ExecutionContext execContext,
SmooksResourceConfiguration saxDriverConfig)
Public constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
append(Source source,
Element appendElement)
Append the content, behind the supplied input stream, to suplied
document element.
|
Document |
parse(Source source)
Document parser.
|
attachNamespaceDeclarationStack, attachXMLReader, configureReader, createInputSource, createXMLReader, detachXMLReader, getExecContext, getInputStream, getReader, getReaders, getSaxDriverConfig, getSAXParserConfiguration, getWriter, getXMLReader, isFeatureOff, isFeatureOn, setReaders
public DOMParser(ExecutionContext execContext)
execContext
- The execution context that the parser is being instantiated on behalf of.public DOMParser(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 Document parse(Source source) throws IOException, SAXException
source
- Source content stream to be parsed.SAXException
- Unable to parse the content.IOException
- Unable to read the input stream.public void append(Source source, Element appendElement) throws IOException, SAXException
source
- Source content stream to be parsed.appendElement
- DOM element to which the content fragment is to
be added.SAXException
- Unable to parse the content.IOException
- Unable to read the input stream.Copyright © 2020. All rights reserved.