|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.emory.mathcs.util.collections.longs.AbstractLongCollection
edu.emory.mathcs.util.collections.longs.AbstractLongSet
Convenience subclass for long sets.
Constructor Summary | |
protected |
AbstractLongSet()
|
Method Summary | |
boolean |
addAll(LongCollection 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(long first,
long last)
Adds to this set all the numbers between first and last, inclusive, that are not already present in this set and belong to this set's domain. |
LongSet |
complementSet()
Returns a complement view of this set. |
boolean |
containsInterval(long first,
long 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. |
long |
max()
The largest number that can be stored in this set. |
long |
min()
The smallest number that can be stored in this set. |
boolean |
removeAll(LongCollection c)
Removes from this set all of its elements that are contained in the specified collection. |
boolean |
removeInterval(long first,
long last)
Removes from this set all the numbers between first and last, inclusive. |
boolean |
retainAll(LongCollection c)
Retains only the elements in this set that are contained in the specified collection. |
boolean |
retainInterval(long first,
long last)
Retains in this set only the numbers between first and last, inclusive. |
Methods inherited from class edu.emory.mathcs.util.collections.longs.AbstractLongCollection |
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.longs.LongSet |
add, clear, contains, containsAll, iterator, remove, size, size64, toArray, toArray |
Constructor Detail |
protected AbstractLongSet()
Method Detail |
public long min()
LongSet
min
in interface LongSet
public long max()
LongSet
max
in interface LongSet
public boolean equals(java.lang.Object obj)
LongSet
equals
in interface LongSet
public int hashCode()
hashCode
in interface LongSet
public boolean isEmpty()
LongSet
isEmpty
in interface LongSet
isEmpty
in class AbstractLongCollection
public boolean addAll(LongCollection c)
LongSet
addAll
in interface LongSet
addAll
in class AbstractLongCollection
public boolean removeAll(LongCollection c)
LongSet
removeAll
in interface LongSet
removeAll
in class AbstractLongCollection
public boolean retainAll(LongCollection c)
LongSet
retainAll
in interface LongSet
retainAll
in class AbstractLongCollection
public boolean containsInterval(long first, long last)
LongSet
containsInterval
in interface LongSet
public boolean addInterval(long first, long last)
LongSet
addInterval
in interface LongSet
first
- the beginning of the interval (inclusive)last
- the end of the interval (inclusive)
LongSet.add(long)
public boolean removeInterval(long first, long last)
LongSet
removeInterval
in interface LongSet
first
- the beginning of the interval (inclusive)last
- the end of the interval (inclusive)
LongSet.remove(long)
,
#removeAll()
public boolean retainInterval(long first, long last)
LongSet
retainInterval
in interface LongSet
first
- the beginning of the interval (inclusive)last
- the end of the interval (inclusive)
#retainAll()
public LongSet complementSet()
LongSet
complementSet
in interface LongSet
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |