net.sf.saxon.xqj

Class SaxonXQForwardSequence

Implemented Interfaces:
XQItemAccessor, XQResultSequence, XQSequence

public class SaxonXQForwardSequence
extends java.lang.Object
implements XQResultSequence

The class is a Saxon implementation of the XQJ interface XQResultSequence. This implementation is used to represent a sequence that can only be read in a forwards direction.

Constructor Summary

SaxonXQForwardSequence(SequenceIterator iterator, SaxonXQConnection connection)

Method Summary

boolean
absolute(int itempos)
void
afterLast()
void
beforeFirst()
void
close()
int
count()
boolean
first()
String
getAtomicValue()
boolean
getBoolean()
byte
getByte()
XQConnection
getConnection()
double
getDouble()
float
getFloat()
int
getInt()
XQItem
getItem()
XMLStreamReader
getItemAsStream()
String
getItemAsString(Properties props)
XQItemType
getItemType()
long
getLong()
Node
getNode()
URI
getNodeUri()
Object
getObject()
int
getPosition()
XMLStreamReader
getSequenceAsStream()
String
getSequenceAsString(Properties props)
short
getShort()
boolean
instanceOf(XQItemType type)
boolean
isAfterLast()
boolean
isBeforeFirst()
boolean
isClosed()
boolean
isFirst()
boolean
isLast()
boolean
isOnItem()
boolean
isScrollable()
boolean
last()
boolean
next()
boolean
previous()
boolean
relative(int itempos)
void
writeItem(OutputStream os, Properties props)
void
writeItem(Writer ow, Properties props)
void
writeItemToResult(Result result)
void
writeItemToSAX(ContentHandler saxHandler)
void
writeSequence(OutputStream os, Properties props)
void
writeSequence(Writer ow, Properties props)
void
writeSequenceToResult(Result result)
void
writeSequenceToSAX(ContentHandler saxHandler)

Constructor Details

SaxonXQForwardSequence

protected SaxonXQForwardSequence(SequenceIterator iterator,
                                 SaxonXQConnection connection)

Method Details

absolute

public boolean absolute(int itempos)
            throws XQException
Specified by:
absolute in interface XQSequence

afterLast

public void afterLast()
            throws XQException
Specified by:
afterLast in interface XQSequence

beforeFirst

public void beforeFirst()
            throws XQException
Specified by:
beforeFirst in interface XQSequence

close

public void close()
            throws XQException
Specified by:
close in interface XQSequence

count

public int count()
            throws XQException
Specified by:
count in interface XQSequence

first

public boolean first()
            throws XQException
Specified by:
first in interface XQSequence

getAtomicValue

public String getAtomicValue()
            throws XQException
Specified by:
getAtomicValue in interface XQItemAccessor

getBoolean

public boolean getBoolean()
            throws XQException
Specified by:
getBoolean in interface XQItemAccessor

getByte

public byte getByte()
            throws XQException
Specified by:
getByte in interface XQItemAccessor

getConnection

public XQConnection getConnection()
Specified by:
getConnection in interface XQResultSequence

getDouble

public double getDouble()
            throws XQException
Specified by:
getDouble in interface XQItemAccessor

getFloat

public float getFloat()
            throws XQException
Specified by:
getFloat in interface XQItemAccessor

getInt

public int getInt()
            throws XQException
Specified by:
getInt in interface XQItemAccessor

getItem

public XQItem getItem()
            throws XQException
Specified by:
getItem in interface XQSequence

getItemAsStream

public XMLStreamReader getItemAsStream()
            throws XQException
Specified by:
getItemAsStream in interface XQItemAccessor

getItemAsString

public String getItemAsString(Properties props)
            throws XQException
Specified by:
getItemAsString in interface XQItemAccessor

getItemType

public XQItemType getItemType()
            throws XQException
Specified by:
getItemType in interface XQItemAccessor

getLong

public long getLong()
            throws XQException
Specified by:
getLong in interface XQItemAccessor

getNode

public Node getNode()
            throws XQException
Specified by:
getNode in interface XQItemAccessor

getNodeUri

public URI getNodeUri()
            throws XQException
Specified by:
getNodeUri in interface XQItemAccessor

getObject

public Object getObject()
            throws XQException
Specified by:
getObject in interface XQItemAccessor

getPosition

public int getPosition()
            throws XQException
Specified by:
getPosition in interface XQSequence

getSequenceAsStream

public XMLStreamReader getSequenceAsStream()
            throws XQException
Specified by:
getSequenceAsStream in interface XQSequence

getSequenceAsString

public String getSequenceAsString(Properties props)
            throws XQException

getShort

public short getShort()
            throws XQException
Specified by:
getShort in interface XQItemAccessor

instanceOf

public boolean instanceOf(XQItemType type)
            throws XQException
Specified by:
instanceOf in interface XQItemAccessor

isAfterLast

public boolean isAfterLast()
            throws XQException
Specified by:
isAfterLast in interface XQSequence

isBeforeFirst

public boolean isBeforeFirst()
            throws XQException
Specified by:
isBeforeFirst in interface XQSequence

isClosed

public boolean isClosed()
Specified by:
isClosed in interface XQSequence

isFirst

public boolean isFirst()
            throws XQException
Specified by:
isFirst in interface XQSequence

isLast

public boolean isLast()
            throws XQException
Specified by:
isLast in interface XQSequence

isOnItem

public boolean isOnItem()
            throws XQException
Specified by:
isOnItem in interface XQSequence

isScrollable

public boolean isScrollable()
            throws XQException
Specified by:
isScrollable in interface XQSequence

last

public boolean last()
            throws XQException
Specified by:
last in interface XQSequence

next

public boolean next()
            throws XQException
Specified by:
next in interface XQSequence

previous

public boolean previous()
            throws XQException
Specified by:
previous in interface XQSequence

relative

public boolean relative(int itempos)
            throws XQException
Specified by:
relative in interface XQSequence

writeItem

public void writeItem(OutputStream os,
                      Properties props)
            throws XQException
Specified by:
writeItem in interface XQItemAccessor

writeItem

public void writeItem(Writer ow,
                      Properties props)
            throws XQException
Specified by:
writeItem in interface XQItemAccessor

writeItemToResult

public void writeItemToResult(Result result)
            throws XQException
Specified by:
writeItemToResult in interface XQItemAccessor

writeItemToSAX

public void writeItemToSAX(ContentHandler saxHandler)
            throws XQException
Specified by:
writeItemToSAX in interface XQItemAccessor

writeSequence

public void writeSequence(OutputStream os,
                          Properties props)
            throws XQException

writeSequence

public void writeSequence(Writer ow,
                          Properties props)
            throws XQException

writeSequenceToResult

public void writeSequenceToResult(Result result)
            throws XQException

writeSequenceToSAX

public void writeSequenceToSAX(ContentHandler saxHandler)
            throws XQException