public class BimodalMutableIntSet extends Object implements MutableIntSet
MutableIntSet that delegates to either a MutableSparseIntSet
or a BitVectorIntSet| Constructor and Description |
|---|
BimodalMutableIntSet() |
BimodalMutableIntSet(BimodalMutableIntSet x) |
BimodalMutableIntSet(int initialSize,
float expansionFactor) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(int i)
Add an integer value to this set.
|
boolean |
addAll(IntSet set)
Add all members of set to this.
|
boolean |
addAllInIntersection(IntSet other,
IntSet filter) |
void |
clear()
remove all elements from this set
|
boolean |
contains(int i) |
boolean |
containsAll(BimodalMutableIntSet that)
TODO: optimize ME!
|
boolean |
containsAny(IntSet that) |
void |
copySet(IntSet set)
Set the value of this to be the same as the value of set
|
void |
foreach(IntSetAction action)
Invoke an action on each element of the Set
|
void |
foreachExcluding(IntSet X,
IntSetAction action)
Invoke an action on each element of the Set, excluding elements of Set X
|
IntSet |
getBackingStore()
use with care
|
IntSet |
intersection(IntSet that)
This implementation must not despoil the original value of "this"
|
void |
intersectWith(IntSet set)
Intersect this with another set.
|
IntIterator |
intIterator() |
boolean |
isEmpty() |
boolean |
isSubset(IntSet that) |
static BimodalMutableIntSet |
makeCopy(IntSet B) |
int |
max() |
boolean |
remove(int i)
Remove an integer from this set.
|
boolean |
removeAll(IntSet that)
TODO: optimize ME!
|
boolean |
sameValue(IntSet that) |
int |
size() |
String |
toString() |
IntSet |
union(IntSet that)
This implementation must not despoil the original value of "this"
|
public BimodalMutableIntSet()
public BimodalMutableIntSet(int initialSize,
float expansionFactor)
public BimodalMutableIntSet(BimodalMutableIntSet x)
IllegalArgumentException - if x is nullpublic void copySet(IntSet set)
MutableIntSetcopySet in interface MutableIntSetpublic boolean addAll(IntSet set)
MutableIntSetaddAll in interface MutableIntSetpublic boolean addAllInIntersection(IntSet other, IntSet filter)
addAllInIntersection in interface MutableIntSetMutableIntSet.addAll(com.ibm.wala.util.intset.IntSet)public boolean add(int i)
MutableIntSetadd in interface MutableIntSeti - integer to addpublic boolean remove(int i)
MutableIntSetremove in interface MutableIntSeti - integer to removepublic void intersectWith(IntSet set) throws UnimplementedError
MutableIntSetintersectWith in interface MutableIntSetUnimplementedErrorpublic boolean contains(int i)
contains in interface IntSetIntSet.contains(int)public IntSet intersection(IntSet that) throws UnimplementedError
IntSetintersection in interface IntSetUnimplementedErrorIntSet.intersection(com.ibm.wala.util.intset.IntSet)public IntSet union(IntSet that)
IntSetunion in interface IntSetIntSet.union(com.ibm.wala.util.intset.IntSet)public boolean isEmpty()
isEmpty in interface IntSetIntSet.isEmpty()public int size()
size in interface IntSetIntSet.size()public IntIterator intIterator()
intIterator in interface IntSetIntSet.intIterator()public void foreach(IntSetAction action)
IntSetforeach in interface IntSetIntSet.foreach(com.ibm.wala.util.intset.IntSetAction)public void foreachExcluding(IntSet X, IntSetAction action)
IntSetforeachExcluding in interface IntSetIntSet.foreachExcluding(com.ibm.wala.util.intset.IntSet,
com.ibm.wala.util.intset.IntSetAction)public int max()
throws IllegalStateException
max in interface IntSetIllegalStateExceptionIntSet.max()public static BimodalMutableIntSet makeCopy(IntSet B) throws UnimplementedError, IllegalArgumentException
public void clear()
MutableIntSetclear in interface MutableIntSetpublic boolean sameValue(IntSet that)
sameValue in interface IntSetthis has the same value as that.IntSet.sameValue(com.ibm.wala.util.intset.IntSet)public boolean isSubset(IntSet that) throws IllegalArgumentException
isSubset in interface IntSetthis is a subset of that.IllegalArgumentExceptionIntSet.isSubset(IntSet)public IntSet getBackingStore()
public boolean containsAny(IntSet that) throws IllegalArgumentException, UnimplementedError
containsAny in interface IntSetIllegalArgumentExceptionUnimplementedErrorIntSet.containsAny(com.ibm.wala.util.intset.IntSet)public boolean removeAll(IntSet that)
IllegalArgumentException - if that is nullpublic boolean containsAll(BimodalMutableIntSet that)
IllegalArgumentException - if that is null