|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.saxon.value.Value
net.sf.saxon.value.IntegerRange
public class IntegerRange
This class represents a sequence of consecutive ascending integers, for example 1 to 50. The integers must be within the range of a Java long.
Field Summary | |
---|---|
long |
end
|
long |
start
|
Fields inherited from class net.sf.saxon.value.Value |
---|
EMPTY_CLASS_ARRAY, INDETERMINATE_ORDERING |
Fields inherited from interface net.sf.saxon.om.ValueRepresentation |
---|
EMPTY_VALUE_ARRAY |
Constructor Summary | |
---|---|
IntegerRange(long start,
long end)
Construct an integer range expression |
Method Summary | |
---|---|
int |
getCardinality()
Determine the cardinality |
long |
getEnd()
Get the last integer in the sequence (inclusive) |
ItemType |
getItemType(TypeHierarchy th)
Determine the data type of the items in the expression, if possible |
int |
getLength()
Get the length of the sequence |
long |
getStart()
Get the first integer in the sequence (inclusive) |
boolean |
isMultiValued()
Determine whether the value is multivalued, that is, whether it is a sequence that potentially contains more than one item |
Item |
itemAt(int n)
Get the n'th item in the sequence (starting from 0). |
SequenceIterator |
iterate()
Return an Iterator to iterate over the values of a sequence. |
Methods inherited from class net.sf.saxon.value.Value |
---|
asItem, asItem, asIterator, asValue, checkPermittedContents, compareTo, convert, convertJavaObjectToXPath, convertToJava, effectiveBooleanValue, equals, fromItem, getCanonicalLexicalRepresentation, getIterator, getSchemaComparable, getStringValue, getStringValueCS, hashCode, iterate, makeQNameValue, process, reduce, stringToNumber, toString |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public long start
public long end
Constructor Detail |
---|
public IntegerRange(long start, long end)
start
- the first integer in the sequence (inclusive)end
- the last integer in the sequence (inclusive). Must be >= startMethod Detail |
---|
public boolean isMultiValued()
isMultiValued
in class Value
public long getStart()
public long getEnd()
public SequenceIterator iterate() throws XPathException
iterate
in class Value
XPathException
- if any dynamic error occurs evaluating the
expressionpublic ItemType getItemType(TypeHierarchy th)
getItemType
in class Value
th
-
public int getCardinality()
getCardinality
in class Value
public Item itemAt(int n) throws XPathException
itemAt
in class Value
n
- position of the required item, counting from zero.
XPathException
public int getLength() throws XPathException
getLength
in class Value
XPathException
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |