@Retention(value=CLASS)
@Target(value=PARAMETER)
public @interface CLocalVariable
name(): The name of the local variable found in the local variable table.ordinal(): The ordinal of the local variable in the local variable table.index(): The variable index of the local variable.name(), ordinal() or index() are set, the local variable will be identified by the name of the method parameter.| Modifier and Type | Optional Element and Description |
|---|---|
int |
index
The var index of the local variable to get.
|
int |
loadOpcode
The opcode used to load the variable.
Only required if the opcode could not be resolved automatically (e.g. |
boolean |
modifiable
Copy the value of the local variable back to the caller method.
When marking a local variable as modifiable the type of the method parameter is deciding the type of the stored local variable. You can use Object to get any non-primitive variable, but it will be stored back as an Object and not as the original type.This may cause a ClassCastException when not careful. |
java.lang.String |
name
The name of the local variable found in the local variable table.
The local variable table is optional in the class file but is required for the name resolution. Use the index if no local variable table is present. |
int |
ordinal
The ordinal of the local variable to get from the local variable table.
The ordinal is counted for every type of local variable (e.g. |
public abstract java.lang.String name
public abstract int ordinal
public abstract int index
public abstract int loadOpcode
public abstract boolean modifiable
Object to get any non-primitive variable, but it will be stored back as an Object and not as the original type.ClassCastException when not careful.