|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.milyn.delivery.AbstractParser
org.milyn.delivery.dom.DOMParser
public class DOMParser
Smooks DOM data stream parser.
This parser can be configured to use a SAX Parser targeted at a specific data stream type. This lets you parse a stream of any type, convert it to a stream of SAX event and so treat the stream as an XML data stream, even when the stream is non-XML. If the configured parser implements theSmooksXMLReader, 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 for SmooksXMLReader implementations.
See SmooksResourceConfiguration for how to add configuration parameters.
-->
</smooks-resource>
| Constructor Summary | |
|---|---|
DOMParser(ExecutionContext execContext)
Public constructor. |
|
DOMParser(ExecutionContext execContext,
SmooksResourceConfiguration saxDriverConfig)
Public constructor. |
|
| Method Summary | |
|---|---|
void |
append(Reader source,
Element appendElement)
Append the content, behind the supplied input stream, to suplied document element. |
Document |
parse(Reader source)
Document parser. |
| Methods inherited from class org.milyn.delivery.AbstractParser |
|---|
createXMLReader, getExecContext, getSaxDriverConfig, getSAXParserConfiguration |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
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.| Method Detail |
|---|
public Document parse(Reader 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(Reader 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.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||