net.sf.saxon.event

Class DocumentSender

Implemented Interfaces:
Locator, LocationProvider, SaxonLocator, SourceLocator

public class DocumentSender
extends java.lang.Object
implements SaxonLocator

Sends an entire document to a Receiver.
Author:
Ruud Diterwich, integrated by Michael Kay

Constructor Summary

DocumentSender(NodeInfo top)
Create a DocumentSender, which takes an input document tree and generates a stream of events for a Receiver

Method Summary

int
getColumnNumber()
int
getLineNumber()
int
getLineNumber(long locationId)
Get the line number within the document or module containing a particular location
String
getPublicId()
String
getSystemId()
String
getSystemId(long locationId)
Get the URI of the document or module containing a particular location
void
send(Receiver receiver)
Send the entire document to the receiver

Constructor Details

DocumentSender

public DocumentSender(NodeInfo top)
Create a DocumentSender, which takes an input document tree and generates a stream of events for a Receiver
Parameters:
top - the document or element node to be turned into a stream of events

Method Details

getColumnNumber

public int getColumnNumber()

getLineNumber

public int getLineNumber()

getLineNumber

public int getLineNumber(long locationId)
Get the line number within the document or module containing a particular location
Specified by:
getLineNumber in interface LocationProvider
Parameters:
locationId - identifier of the location in question (as passed down the Receiver pipeline)
Returns:
the line number within the document or module.

getPublicId

public String getPublicId()

getSystemId

public String getSystemId()

getSystemId

public String getSystemId(long locationId)
Get the URI of the document or module containing a particular location
Specified by:
getSystemId in interface LocationProvider
Parameters:
locationId - identifier of the location in question (as passed down the Receiver pipeline)
Returns:
the URI of the document or module.

send

public void send(Receiver receiver)
            throws XPathException
Send the entire document to the receiver