net.sf.saxon.sort
public class IntRangeSet extends Object implements Serializable, IntSet
Constructor Summary | |
---|---|
IntRangeSet()
Create an empty set | |
IntRangeSet(IntRangeSet input)
Create one IntRangeSet as a copy of another | |
IntRangeSet(int[] startPoints, int[] endPoints)
Create an IntRangeSet given the start points and end points of the integer ranges.
|
Method Summary | |
---|---|
boolean | add(int value)
Add an integer to the set |
void | addRange(int low, int high)
Add a range of integers to the set.
|
void | clear() |
boolean | contains(int value) |
boolean | containsAll(IntSet other)
Test if this set is a superset of another set |
boolean | equals(Object other)
Test whether this set has exactly the same members as another set. |
int[] | getEndPoints()
Get the end points of the ranges |
int | getNumberOfRanges()
Get the number of ranges actually in use |
int[] | getStartPoints()
Get the start points of the ranges |
int | hashCode()
Construct a hash key that supports the equals() test |
boolean | isEmpty() |
IntIterator | iterator()
Get an iterator over the values |
boolean | remove(int value) |
int | size() |
String | toString() |
Parameters: input the IntRangeSet to be copied
Parameters: startPoints the start points of the integer ranges endPoints the end points of the integer ranges
Throws: IllegalArgumentException if the two arrays are different lengths. Other error conditions in the input are not currently detected.
Parameters: value the integer to be added
Returns: true if the integer was added, false if it was already present
Parameters: low the low end of the new range high the high end of the new range