|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.emory.mathcs.util.collections.ints.AbstractIntCollection
edu.emory.mathcs.util.collections.ints.AbstractIntSet
Convenience subclass for int sets.
Constructor Summary | |
protected |
AbstractIntSet()
|
Method Summary | |
boolean |
addAll(IntCollection c)
Adds all of the elements in the specified collection to this set if they're not already present, and if they fall within this set's domain. |
boolean |
addInterval(int first,
int last)
Adds to this set all the numbers between first and last, inclusive, that are not already present in this set and beint to this set's domain. |
IntSet |
complementSet()
Returns a complement view of this set. |
boolean |
containsInterval(int first,
int last)
Returns true if this set contains all the numbers between first and last, inclusive; false otherwise. |
boolean |
equals(java.lang.Object obj)
Two sets are equal if they consists of the same elements. |
int |
hashCode()
|
boolean |
isEmpty()
Returns true if this set is empty; false otherwise. |
int |
max()
The largest number that can be stored in this set. |
int |
min()
The smallest number that can be stored in this set. |
boolean |
removeAll(IntCollection c)
Removes from this set all of its elements that are contained in the specified collection. |
boolean |
removeInterval(int first,
int last)
Removes from this set all the numbers between first and last, inclusive. |
boolean |
retainAll(IntCollection c)
Retains only the elements in this set that are contained in the specified collection. |
boolean |
retainInterval(int first,
int last)
Retains in this set only the numbers between first and last, inclusive. |
Methods inherited from class edu.emory.mathcs.util.collections.ints.AbstractIntCollection |
add, clear, contains, containsAll, iterator, remove, size, size64, toArray, toArray, toString |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface edu.emory.mathcs.util.collections.ints.IntSet |
add, clear, contains, containsAll, iterator, remove, size, size64, toArray, toArray |
Constructor Detail |
protected AbstractIntSet()
Method Detail |
public int min()
IntSet
min
in interface IntSet
public int max()
IntSet
max
in interface IntSet
public boolean equals(java.lang.Object obj)
IntSet
equals
in interface IntSet
public int hashCode()
hashCode
in interface IntSet
public boolean isEmpty()
IntSet
isEmpty
in interface IntSet
isEmpty
in class AbstractIntCollection
public boolean addAll(IntCollection c)
IntSet
addAll
in interface IntSet
addAll
in class AbstractIntCollection
public boolean removeAll(IntCollection c)
IntSet
removeAll
in interface IntSet
removeAll
in class AbstractIntCollection
public boolean retainAll(IntCollection c)
IntSet
retainAll
in interface IntSet
retainAll
in class AbstractIntCollection
public boolean containsInterval(int first, int last)
IntSet
containsInterval
in interface IntSet
public boolean addInterval(int first, int last)
IntSet
addInterval
in interface IntSet
first
- the beginning of the interval (inclusive)last
- the end of the interval (inclusive)
IntSet.add(int)
public boolean removeInterval(int first, int last)
IntSet
removeInterval
in interface IntSet
first
- the beginning of the interval (inclusive)last
- the end of the interval (inclusive)
IntSet.remove(int)
,
#removeAll()
public boolean retainInterval(int first, int last)
IntSet
retainInterval
in interface IntSet
first
- the beginning of the interval (inclusive)last
- the end of the interval (inclusive)
#retainAll()
public IntSet complementSet()
IntSet
complementSet
in interface IntSet
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |