public class SingleTypeState extends TypeState
TypeState.TypesObjectsIterator
Modifier and Type | Field and Description |
---|---|
protected BigBang |
bigbang |
protected boolean |
canBeNull
Can this type state represent the null value?
|
protected AnalysisObject[] |
objects
The objects of this type state.
|
properties
Modifier | Constructor and Description |
---|---|
|
SingleTypeState(BigBang bb,
boolean canBeNull,
int properties,
AnalysisObject... objects)
Creates a new type state from incoming objects.
|
|
SingleTypeState(BigBang bb,
boolean canBeNull,
int properties,
ArrayList<AnalysisObject> objects) |
protected |
SingleTypeState(BigBang bb,
boolean canBeNull,
SingleTypeState other)
Create a type state with the same content and a reversed canBeNull value.
|
Modifier and Type | Method and Description |
---|---|
boolean |
canBeNull() |
protected boolean |
checkObjects(org.graalvm.compiler.options.OptionValues options) |
boolean |
containsType(AnalysisType exactType)
Returns true if this type state contains the type, otherwise it returns false.
|
boolean |
equals(Object o) |
AnalysisType |
exactType()
If this type state has a single, exact type it returns that type, otherwise it returns null.
|
TypeState |
exactTypeState(BigBang bb,
AnalysisType exactType)
This method is needed for accessing the SingleTypeState associated with an specific type of a
MutiTypeState, e.g.
|
protected TypeState |
forCanBeNull(BigBang bb,
boolean stateCanBeNull) |
boolean |
hasExactTypes(BitSet inputTypesBitSet)
Returns true if the type state contains exact the same types as the bit set.
|
int |
hashCode() |
void |
noteMerge(BigBang bb)
Note that the objects of this type state have been merged.
|
AnalysisObject[] |
objects()
Returns the objects as an array.
|
AnalysisObject[] |
objectsArray(AnalysisType type)
Returns the objects corresponding to the type.
|
int |
objectsCount()
Get the number of objects.
|
protected Iterator<AnalysisObject> |
objectsIterator(AnalysisType type)
Provides an iterator for the objects corresponding to the type.
|
String |
toString() |
int |
typesCount()
Get the number of types.
|
protected Iterator<AnalysisType> |
typesIterator()
Provides an iterator over the types.
|
closeToAllInstantiated, containsObject, forAllocation, forAllocation, forClone, forConstant, forContextInsensitiveTypeState, forEmpty, forExactType, forExactType, forExactTypes, forIntersection, forNonNull, forNonNullObject, forNull, forSubtraction, forUnion, getId, getProperties, getTypesObjectsIterator, isAllocation, isConstant, isEmpty, isMultiTypeState, isNull, isSingleTypeState, objects, objectsStream, setId, types, typesStream, verifyDeclaredType
protected final BigBang bigbang
protected final AnalysisObject[] objects
protected final boolean canBeNull
public SingleTypeState(BigBang bb, boolean canBeNull, int properties, ArrayList<AnalysisObject> objects)
public SingleTypeState(BigBang bb, boolean canBeNull, int properties, AnalysisObject... objects)
protected SingleTypeState(BigBang bb, boolean canBeNull, SingleTypeState other)
protected boolean checkObjects(org.graalvm.compiler.options.OptionValues options)
public int typesCount()
TypeState
typesCount
in class TypeState
public boolean hasExactTypes(BitSet inputTypesBitSet)
TypeState
hasExactTypes
in class TypeState
public AnalysisType exactType()
TypeState
protected Iterator<AnalysisType> typesIterator()
TypeState
typesIterator
in class TypeState
public boolean containsType(AnalysisType exactType)
TypeState
containsType
in class TypeState
public final int objectsCount()
TypeState
objectsCount
in class TypeState
public final AnalysisObject[] objects()
TypeState
public AnalysisObject[] objectsArray(AnalysisType type)
TypeState
objectsArray
in class TypeState
protected Iterator<AnalysisObject> objectsIterator(AnalysisType type)
TypeState
objectsIterator
in class TypeState
public TypeState exactTypeState(BigBang bb, AnalysisType exactType)
TypeState
exactTypeState
in class TypeState
protected TypeState forCanBeNull(BigBang bb, boolean stateCanBeNull)
forCanBeNull
in class TypeState
public void noteMerge(BigBang bb)