public class ParticularReferenceValue extends IdentifiedReferenceValue
ParticularReferenceValue
represents a particular reference value, i.e. a reference
with an associated value. E.g., a String with the value "HelloWorld".Modifier and Type | Field and Description |
---|---|
static boolean |
ARRAY_EXCEPTIONS |
id
ALLOW_INCOMPLETE_CLASS_HIERARCHY, INCOMPLETE_CLASS_HIERARCHY, mayBeExtension, mayBeNull, referencedClass, type, WARN_INCOMPLETE_CLASS_HIERARCHY
ALWAYS, MAYBE, NEVER, TYPE_DOUBLE, TYPE_FLOAT, TYPE_INSTRUCTION_OFFSET, TYPE_INTEGER, TYPE_LONG, TYPE_REFERENCE, TYPE_TOP, TYPE_UNKNOWN
Constructor and Description |
---|
ParticularReferenceValue(Clazz referencedClass,
ValueFactory valueFactory,
java.lang.Object referenceID,
@NotNull AnalyzedObject value)
Create a new Instance with the given type, the class it is referenced in, and its actual value.
|
Modifier and Type | Method and Description |
---|---|
ReferenceValue |
cast(java.lang.String type,
Clazz referencedClass,
ValueFactory valueFactory,
boolean alwaysCast)
Returns this ReferenceValue, cast to the given type.
|
int |
equal(ReferenceValue other)
Returns whether this ReferenceValue is equal to the given other ReferenceValue.
|
boolean |
equals(java.lang.Object o) |
ReferenceValue |
generalize(ParticularReferenceValue other)
Returns the generalization of this ReferenceValue and the given other ParticularReferenceValue.
|
ReferenceValue |
generalize(ReferenceValue other)
Returns the generalization of this ReferenceValue and the given other ReferenceValue.
|
@NotNull AnalyzedObject |
getValue() |
int |
hashCode() |
int |
instanceOf(java.lang.String otherType,
Clazz otherReferencedClass)
Returns whether the type is an instance of the given type.
|
int |
isNull()
Returns whether this ReferenceValue is
null . |
boolean |
isParticular()
Returns whether this Value represents a single particular (known) value.
|
java.lang.String |
toString() |
java.lang.Object |
value()
Deprecated.
|
equal, generalize, isSpecific
allowsIncompleteClassHierarchy, arrayStore, doubleArrayLoad, equal, floatArrayLoad, generalize, generalizeMayBeNull, getReferencedClass, getType, integerArrayLoad, internalType, longArrayLoad, mayBeExtension, referenceArrayLoad
arrayLength, computationalType, equal, equal, equal, equal, equal, equal, equal, generalize, generalize, generalize, generalize, generalize, generalize, generalize, isNotNull, notEqual, referenceValue
category1Value, isCategory2
category2Value, copyIfMutable, doubleValue, floatValue, instructionOffsetValue, integerValue, longValue
public ParticularReferenceValue(Clazz referencedClass, ValueFactory valueFactory, java.lang.Object referenceID, @NotNull @NotNull AnalyzedObject value)
@Deprecated public java.lang.Object value()
getValue()
.value
in class ReferenceValue
@NotNull public @NotNull AnalyzedObject getValue()
getValue
in class ReferenceValue
public boolean isParticular()
Value
isParticular
in class TypedReferenceValue
public int isNull()
ReferenceValue
null
.isNull
in class TypedReferenceValue
NEVER
, MAYBE
, or ALWAYS
.public int instanceOf(java.lang.String otherType, Clazz otherReferencedClass)
ReferenceValue
instanceOf
in class TypedReferenceValue
public ReferenceValue cast(java.lang.String type, Clazz referencedClass, ValueFactory valueFactory, boolean alwaysCast)
ReferenceValue
cast
in class TypedReferenceValue
public ReferenceValue generalize(ReferenceValue other)
ReferenceValue
generalize
in class IdentifiedReferenceValue
public ReferenceValue generalize(ParticularReferenceValue other)
ReferenceValue
generalize
in class ReferenceValue
public int hashCode()
hashCode
in class IdentifiedReferenceValue
public boolean equals(java.lang.Object o)
equals
in class IdentifiedReferenceValue
public int equal(ReferenceValue other)
ReferenceValue
equal
in class IdentifiedReferenceValue
NEVER
, MAYBE
, or ALWAYS
.public java.lang.String toString()
toString
in class IdentifiedReferenceValue