public class LocalVariableInfo
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private java.util.Hashtable |
names
The names database.
|
private java.util.Hashtable |
types
The types database.
|
Constructor and Description |
---|
LocalVariableInfo() |
Modifier and Type | Method and Description |
---|---|
private void |
add(int offset,
java.lang.String name,
Type t)
Adds information about name and type for a given offset.
|
void |
add(java.lang.String name,
int startpc,
int length,
Type t)
Adds some information about this local variable (slot).
|
java.lang.String |
getName(int offset)
Returns the name of the local variable that uses this local
variable slot at the given bytecode offset.
|
Type |
getType(int offset)
Returns the type of the local variable that uses this local
variable slot at the given bytecode offset.
|
private void |
setName(int offset,
java.lang.String name)
Adds a name of a local variable and a certain slot to our 'names'
(Hashtable) database.
|
private void |
setType(int offset,
Type t)
Adds a type of a local variable and a certain slot to our 'types'
(Hashtable) database.
|
private java.util.Hashtable types
private java.util.Hashtable names
private void setName(int offset, java.lang.String name)
private void setType(int offset, Type t)
public Type getType(int offset)
public java.lang.String getName(int offset)
public void add(java.lang.String name, int startpc, int length, Type t) throws LocalVariableInfoInconsistentException
LocalVariableInfoInconsistentException
- if the new information conflicts
with already gathered information.private void add(int offset, java.lang.String name, Type t) throws LocalVariableInfoInconsistentException
LocalVariableInfoInconsistentException
- if the new information conflicts
with already gathered information.