edu.rice.cs.dynamicjava.symbol
Class LocalVariable
java.lang.Object
edu.rice.cs.dynamicjava.symbol.LocalVariable
- All Implemented Interfaces:
- Variable
public class LocalVariable
- extends java.lang.Object
- implements Variable
Represents a local variable declaration. To allow usage as a key in maps, every instance is
considered unique, and clients should not create multiple instances to describe the same entity.
|
Constructor Summary |
LocalVariable(java.lang.String name,
Type type,
boolean isFinal)
Create a local variable with the given name, type, and "final" modifier. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
LocalVariable
public LocalVariable(java.lang.String name,
Type type,
boolean isFinal)
- Create a local variable with the given name, type, and "final" modifier. Until sophisticated
control-flow analysis is implemented, variables that are declared final but uninitialized
should be considered non-final.
declaredName
public java.lang.String declaredName()
- Specified by:
declaredName in interface Variable
type
public Type type()
- Specified by:
type in interface Variable
isFinal
public boolean isFinal()
- Specified by:
isFinal in interface Variable
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Object