Package com.schibsted.spt.data.jslt.impl
Class VariableInfo
- java.lang.Object
-
- com.schibsted.spt.data.jslt.impl.VariableInfo
-
- Direct Known Subclasses:
LetInfo,ParameterInfo
public abstract class VariableInfo extends java.lang.ObjectClass encapsulating what we know about a specific variable. Keeps track of the stack frame slot, but mostly used for optimizations.
-
-
Constructor Summary
Constructors Constructor Description VariableInfo(Location location)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description ExpressionNodegetDeclaration()The expression that computes this variable's value.LocationgetLocation()abstract java.lang.StringgetName()intgetSlot()intgetUsageCount()voidincrementUsageCount()booleanisLet()voidsetSlot(int slot)
-
-
-
Field Detail
-
slot
private int slot
-
location
private Location location
-
usages
private int usages
-
-
Constructor Detail
-
VariableInfo
public VariableInfo(Location location)
-
-
Method Detail
-
getName
public abstract java.lang.String getName()
-
setSlot
public void setSlot(int slot)
-
getSlot
public int getSlot()
-
getLocation
public Location getLocation()
-
incrementUsageCount
public void incrementUsageCount()
-
getUsageCount
public int getUsageCount()
-
isLet
public boolean isLet()
-
getDeclaration
public ExpressionNode getDeclaration()
The expression that computes this variable's value. null for parameters, because in that case we don't know the expression.
-
-