junc.ast
Class VariableExpNode

java.lang.Object
  |
  +--antlr.BaseAST
        |
        +--antlr.CommonAST
              |
              +--junc.ast.JUnCASTNode
                    |
                    +--junc.ast.ExpressionNode
                          |
                          +--junc.ast.VariableExpNode
All Implemented Interfaces:
antlr.collections.AST, java.io.Serializable
Direct Known Subclasses:
FormalExpNode, LocalExpNode

public abstract class VariableExpNode
extends ExpressionNode

See Also:
Serialized Form

Field Summary
 junc.symtab.Symbol name
           
 
Fields inherited from class junc.ast.ExpressionNode
falseList, leftValue, statementExpression, trueList, type
 
Fields inherited from class antlr.BaseAST
down, right
 
Constructor Summary
VariableExpNode(junc.symtab.Symbol name)
           
 
Method Summary
 void translate(org.apache.bcel.generic.ClassGen classGen, org.apache.bcel.generic.MethodGen methodGen)
          Describe translate method here.
 org.apache.bcel.generic.BranchHandle translateSynthesized(org.apache.bcel.generic.ClassGen classGen, org.apache.bcel.generic.MethodGen methodGen)
          First translate the expression and then synthesize it.
 boolean variableExp()
          Determines if the expression is an access to a local or a formal param.
 
Methods inherited from class junc.ast.ExpressionNode
addFalseList, addTrueList, appendToFalseList, appendToTrueList, backPatch, desynthesize, evaluate, evaluateExp, leftValue, lookupPrimop, superExp, synthesize, thisExp, thisOrSuperExp, type, typeCheck, typeExp
 
Methods inherited from class junc.ast.JUnCASTNode
getColumnNumber, getLineNumber, setColumnNumber, setLineNumber
 
Methods inherited from class antlr.CommonAST
getText, getType, initialize, initialize, initialize, setText, setType
 
Methods inherited from class antlr.BaseAST
addChild, decode, encode, equals, equalsList, equalsListPartial, equalsTree, equalsTreePartial, findAll, findAllPartial, getFirstChild, getNextSibling, removeChildren, setFirstChild, setNextSibling, setVerboseStringConversion, toString, toStringList, toStringTree, xmlSerialize, xmlSerializeNode, xmlSerializeRootClose, xmlSerializeRootOpen
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

name

public junc.symtab.Symbol name
Constructor Detail

VariableExpNode

public VariableExpNode(junc.symtab.Symbol name)
Method Detail

variableExp

public boolean variableExp()
Description copied from class: ExpressionNode
Determines if the expression is an access to a local or a formal param. Redefined in the VariableExpNode class.

Overrides:
variableExp in class ExpressionNode
Returns:
a boolean value

translate

public void translate(org.apache.bcel.generic.ClassGen classGen,
                      org.apache.bcel.generic.MethodGen methodGen)
Description copied from class: ExpressionNode
Describe translate method here.

Overrides:
translate in class ExpressionNode
Parameters:
classGen - a ClassGen value
methodGen - a MethodGen value

translateSynthesized

public org.apache.bcel.generic.BranchHandle translateSynthesized(org.apache.bcel.generic.ClassGen classGen,
                                                                 org.apache.bcel.generic.MethodGen methodGen)
Description copied from class: ExpressionNode
First translate the expression and then synthesize it. This method is redefined in those expressions that already synthesize their result to avoid synthesize, de-synthesize, synthesize sequences.

Overrides:
translateSynthesized in class ExpressionNode
Parameters:
classGen - a ClassGen value
methodGen - a MethodGen value
Returns:
a BranchHandle value