public class Variables
extends java.lang.Object
Value
instances. Values are
generalizations of all values that have been stored in the respective variables.Modifier and Type | Field and Description |
---|---|
protected int |
size |
protected Value[] |
values |
Constructor and Description |
---|
Variables(int size)
Creates a new Variables object with a given maximum number of variables.
|
Variables(Variables variables)
Creates a Variables object that is a copy of the given Variables object.
|
Modifier and Type | Method and Description |
---|---|
ReferenceValue |
aload(int index)
Loads the ReferenceValue from the variable with the given index.
|
DoubleValue |
dload(int index)
Loads the DoubleValue from the variable with the given index.
|
boolean |
equals(java.lang.Object object) |
FloatValue |
fload(int index)
Loads the FloatValue from the variable with the given index.
|
boolean |
generalize(Variables other,
boolean clearConflictingOtherVariables)
Generalizes the values of this Variables object with the values of the given Variables object.
|
Value |
getValue(int index)
Gets the Value of the variable with the given index, without disturbing it.
|
int |
hashCode() |
IntegerValue |
iload(int index)
Loads the IntegerValue from the variable with the given index.
|
void |
initialize(Variables other)
Initializes the values of this Variables object with the values of the given Variables object.
|
LongValue |
lload(int index)
Loads the LongValue from the variable with the given index.
|
Value |
load(int index)
Loads the Value from the variable with the given index.
|
InstructionOffsetValue |
oload(int index)
Loads the InstructionOffsetValue from the variable with the given index.
|
void |
replaceReferences(Value toReplace,
Value replacement)
Replaces all the references to with references to .
|
void |
reset(int size)
Resets this Variables object, so that it can be reused.
|
int |
size()
Returns the number of variables.
|
void |
store(int index,
Value value)
Stores the given Value at the given variable index.
|
java.lang.String |
toString() |
protected Value[] values
protected int size
public Variables(int size)
public Variables(Variables variables)
public void reset(int size)
public void initialize(Variables other)
public boolean generalize(Variables other, boolean clearConflictingOtherVariables)
clearConflictingOtherVariables
- specifies whether the other variables should be cleared
too, in case of conflicts.public int size()
public Value getValue(int index)
public void store(int index, Value value)
public Value load(int index)
public IntegerValue iload(int index)
public LongValue lload(int index)
public FloatValue fload(int index)
public DoubleValue dload(int index)
public ReferenceValue aload(int index)
public InstructionOffsetValue oload(int index)
public void replaceReferences(Value toReplace, Value replacement)
public boolean equals(java.lang.Object object)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object