public abstract class Sender
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static Receiver |
makeValidator(Receiver receiver,
java.lang.String systemId,
ParseOptions options) |
static void |
send(javax.xml.transform.Source source,
Receiver receiver,
ParseOptions options)
Send the contents of a Source to a Receiver.
|
static void |
sendDocumentInfo(NodeInfo top,
Receiver receiver,
Location location)
Send a copy of a Saxon NodeInfo representing a document or element node to a receiver
|
public static void send(javax.xml.transform.Source source,
Receiver receiver,
ParseOptions options)
throws XPathException
source - the source to be copied. Note that if the Source contains an InputStream
or Reader then it will be left open, unless it is an AugmentedSource with the pleaseCloseAfterUse
flag set. On the other hand, if it contains a URI that needs to be dereferenced to obtain
an InputStream, then the InputStream will be closed after use.receiver - the destination to which it is to be copied. The pipelineConfiguration
of this receiver must have been initialized. The implementation sends a sequence
of events to the Receiver, starting with an Outputter.open() call
and ending with Outputter.close(); this will be a regular event sequence
as defined by RegularSequenceChecker.options - Parsing options. If source is an AugmentedSource, any options set in the
AugmentedSource are used in preference to those set in options. If neither specifies
a particular option, the defaults from the Configuration are used. If null is supplied,
the parse options from the PipelineConfiguration of the receiver are used.XPathException - if any error occurspublic static void sendDocumentInfo(NodeInfo top, Receiver receiver, Location location) throws XPathException
top - the root of the subtree to be send. Despite the method name, this can be a document
node or an element nodereceiver - the destination to receive the eventsXPathException - if any error occursjava.lang.IllegalArgumentException - if the node is not a document or element nodepublic static Receiver makeValidator(Receiver receiver, java.lang.String systemId, ParseOptions options) throws XPathException
XPathExceptionCopyright (c) 2004-2022 Saxonica Limited. All rights reserved.