Package net.sf.saxon.pull
Class ActiveStAXSource
- java.lang.Object
-
- net.sf.saxon.pull.ActiveStAXSource
-
- All Implemented Interfaces:
javax.xml.transform.Source,ActiveSource
public class ActiveStAXSource extends java.lang.Object implements ActiveSource
An extension of StAXSource that makes the source active: that is, able to deliver itself to a SaxonReceiver.Saxon can only handle a StAXSource that wraps an XMLStreamReader (not an XMLEventReader)
-
-
Constructor Summary
Constructors Constructor Description ActiveStAXSource(javax.xml.transform.stax.StAXSource source)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeliver(Receiver receiver, ParseOptions options)Deliver the content of the source to a supplied Receiver.static ActiveStAXSourcefromStAXSource(javax.xml.transform.stax.StAXSource source)java.lang.StringgetSystemId()voidsetSystemId(java.lang.String systemId)
-
-
-
Method Detail
-
fromStAXSource
public static ActiveStAXSource fromStAXSource(javax.xml.transform.stax.StAXSource source) throws javax.xml.stream.XMLStreamException
- Throws:
javax.xml.stream.XMLStreamException
-
setSystemId
public void setSystemId(java.lang.String systemId)
- Specified by:
setSystemIdin interfacejavax.xml.transform.Source
-
getSystemId
public java.lang.String getSystemId()
- Specified by:
getSystemIdin interfacejavax.xml.transform.Source
-
deliver
public void deliver(Receiver receiver, ParseOptions options) throws XPathException
Description copied from interface:ActiveSourceDeliver the content of the source to a supplied Receiver.For many (but not all) implementations of
Source, this method consumes the source and can therefore only be called once.- Specified by:
deliverin interfaceActiveSource- Parameters:
receiver- the receiver to which events representing the parsed XML document will be sentoptions- options for parsing the source- Throws:
XPathException- if parsing fails for any reason. The detailed diagnostics will have been sent to the error reporter.
-
-