public interface Frame
Object.| Modifier and Type | Method and Description |
|---|---|
default void |
clear(int slot)
Clears the given indexed slot in the frame.
|
default void |
copy(int srcSlot,
int destSlot)
Copies, including the type, from one slot to another.
|
Object[] |
getArguments()
Retrieves the arguments object from this frame.
|
default Object |
getAuxiliarySlot(int slot) |
default boolean |
getBoolean(int slot)
Read access to a local variable of type boolean.
|
default byte |
getByte(int slot)
Read access to a local variable of type byte.
|
default double |
getDouble(int slot)
Read access to a local variable of type double.
|
default float |
getFloat(int slot)
Read access to a local variable of type float.
|
FrameDescriptor |
getFrameDescriptor() |
default int |
getInt(int slot)
Read access to a local variable of type int.
|
default long |
getLong(int slot)
Read access to a local variable of type long.
|
default Object |
getObject(int slot)
Read access to a local variable of type
Object. |
default byte |
getTag(int slot)
Determines the actual
FrameSlotKind of the value in the slot, and returns it as
FrameSlotKind.tag. |
default Object |
getValue(int slot)
Read access to a local variable of any type.
|
default boolean |
isBoolean(int slot)
Check whether the given indexed slot is of type boolean.
|
default boolean |
isByte(int slot)
Check whether the given indexed slot is of type byte.
|
default boolean |
isDouble(int slot)
Check whether the given indexed slot is of type double.
|
default boolean |
isFloat(int slot)
Check whether the given indexed slot is of type float.
|
default boolean |
isInt(int slot)
Check whether the given indexed slot is of type int.
|
default boolean |
isLong(int slot)
Check whether the given indexed slot is of type long.
|
default boolean |
isObject(int slot)
Check whether the given indexed slot is of type object.
|
MaterializedFrame |
materialize()
Materializes this frame, which allows it to be stored in a field or cast to
Object. |
default void |
setAuxiliarySlot(int slot,
Object value)
Sets the value of the given auxiliary slot.
|
default void |
setBoolean(int slot,
boolean value)
Write access to a local variable of type boolean.
|
default void |
setByte(int slot,
byte value)
Write access to a local variable of type byte.
|
default void |
setDouble(int slot,
double value)
Write access to a local variable of type double.
|
default void |
setFloat(int slot,
float value)
Write access to a local variable of type float.
|
default void |
setInt(int slot,
int value)
Write access to a local variable of type int.
|
default void |
setLong(int slot,
long value)
Write access to a local variable of type long.
|
default void |
setObject(int slot,
Object value)
Write access to a local variable of type
Object. |
default void |
swap(int first,
int second)
Swaps, including the type, the contents of two slots.
|
FrameDescriptor getFrameDescriptor()
Object[] getArguments()
MaterializedFrame materialize()
Object.default Object getObject(int slot) throws FrameSlotTypeException
Object.slot - the slot of the local variableFrameSlotTypeException - if the current value is not of type objectdefault void setObject(int slot,
Object value)
Object.slot - the slot of the local variablevalue - the new value of the local variabledefault byte getByte(int slot)
throws FrameSlotTypeException
slot - the slot of the local variableFrameSlotTypeExceptiondefault void setByte(int slot,
byte value)
slot - the slot of the local variablevalue - the new value of the local variabledefault boolean getBoolean(int slot)
throws FrameSlotTypeException
slot - the slot of the local variableFrameSlotTypeException - if the current value is not of type booleandefault void setBoolean(int slot,
boolean value)
slot - the slot of the local variablevalue - the new value of the local variabledefault int getInt(int slot)
throws FrameSlotTypeException
slot - the slot of the local variableFrameSlotTypeException - if the current value is not of type intdefault void setInt(int slot,
int value)
slot - the slot of the local variablevalue - the new value of the local variabledefault long getLong(int slot)
throws FrameSlotTypeException
slot - the slot of the local variableFrameSlotTypeException - if the current value is not of type longdefault void setLong(int slot,
long value)
slot - the slot of the local variablevalue - the new value of the local variabledefault float getFloat(int slot)
throws FrameSlotTypeException
slot - the slot of the local variableFrameSlotTypeException - if the current value is not of type floatdefault void setFloat(int slot,
float value)
slot - the slot of the local variablevalue - the new value of the local variabledefault double getDouble(int slot)
throws FrameSlotTypeException
slot - the slot of the local variableFrameSlotTypeException - if the current value is not of type doubledefault void setDouble(int slot,
double value)
slot - the slot of the local variablevalue - the new value of the local variabledefault Object getValue(int slot)
slot - the slot of the local variabledefault void copy(int srcSlot,
int destSlot)
srcSlot - the slot of the source local variabledestSlot - the slot of the target local variabledefault void swap(int first,
int second)
first - the slot of the first local variablesecond - the slot of the second local variabledefault byte getTag(int slot)
FrameSlotKind of the value in the slot, and returns it as
FrameSlotKind.tag.slot - the slot of the local variabledefault boolean isObject(int slot)
slot - the slot of the local variabledefault boolean isByte(int slot)
slot - the slot of the local variabledefault boolean isBoolean(int slot)
slot - the slot of the local variabledefault boolean isInt(int slot)
slot - the slot of the local variabledefault boolean isLong(int slot)
slot - the slot of the local variabledefault boolean isFloat(int slot)
slot - the slot of the local variabledefault boolean isDouble(int slot)
slot - the slot of the local variabledefault void clear(int slot)
FrameSlotTypeException.
This method is intended to be used for implementations of liveness analysis. As such, the compiler will find and report any inconsistency with respect to liveness analysis when using this method, such as clearing a slot in a branch, but not on another one, and their execution merge.
Liveness analysis implementations are expected to clear unused slots on method entry
slot - the slot of the local variabledefault Object getAuxiliarySlot(int slot)
slot - the auxiliary slot index to querynull if it was never set (not the
frame descriptor's default value)default void setAuxiliarySlot(int slot,
Object value)
slot - the auxiliary slot indexvalue - the new value