Package qilin.core.sets
Class HybridPointsToSet
java.lang.Object
qilin.core.sets.PointsToSetInternal
qilin.core.sets.HybridPointsToSet
Hybrid implementation of points-to set, which uses an explicit array for small sets, and a bit
vector for large sets.
- Author:
- Ondrej Lhotak
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanadd(int idx) Adds idx to this set, returns true if idx was not already in this set.booleanaddAll(PointsToSetInternal other, PointsToSetInternal exclude) Adds contents of other into this set, returns true if this set changed.voidclear()booleancontains(int idx) Returns true iff the set contains node idx.booleanCalls v's visit method on all nodes in this set.static HybridPointsToSetbooleanisEmpty()Returns true if this set contains no run-time objects.iterator()intsize()Methods inherited from class qilin.core.sets.PointsToSetInternal
hasNonEmptyIntersection
-
Constructor Details
-
HybridPointsToSet
public HybridPointsToSet()
-
-
Method Details
-
getEmptySet
-
isEmpty
public boolean isEmpty()Returns true if this set contains no run-time objects.- Specified by:
isEmptyin classPointsToSetInternal
-
clear
public void clear()- Specified by:
clearin classPointsToSetInternal
-
addAll
Adds contents of other into this set, returns true if this set changed.- Specified by:
addAllin classPointsToSetInternal
-
iterator
- Specified by:
iteratorin classPointsToSetInternal
-
size
public int size()- Specified by:
sizein classPointsToSetInternal
-
forall
Calls v's visit method on all nodes in this set.- Specified by:
forallin classPointsToSetInternal
-
contains
public boolean contains(int idx) Returns true iff the set contains node idx.- Specified by:
containsin classPointsToSetInternal
-
add
public boolean add(int idx) Adds idx to this set, returns true if idx was not already in this set.- Specified by:
addin classPointsToSetInternal
-