ast
Class DispatchExpr

java.lang.Object
  extended by ast.ASTNode
      extended by ast.Expr
          extended by ast.DispatchExpr

public class DispatchExpr
extends Expr

The DispatchExpr class represents a dispatch expression. It contains a reference expression (refExpr), a method name (methodName, and a list of actual parameter expressions (actualList).

See Also:
ASTNode, Expr

Field Summary
protected  ExprList actualList
          The list of actual parameter expressions
protected  java.lang.String methodName
          The name of the method
protected  Expr refExpr
          The reference expression (produces the object to dispatch on)
 
Fields inherited from class ast.ASTNode
charNum, lineNum, lineStr
 
Constructor Summary
DispatchExpr(int lineNum, Expr refExpr, java.lang.String methodName, ExprList actualList)
          DispatchExpr constructor
 
Method Summary
 java.lang.Object accept(visitor.Visitor v, java.lang.Object o)
          Visitor method
 ExprList getActualList()
          Get the list of actual parameter expressions
 java.lang.String getMethodName()
          Get the method name
 Expr getRefExpr()
          Get the reference expression
 
Methods inherited from class ast.Expr
getExprType, setExprType
 
Methods inherited from class ast.ASTNode
getLineNum
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

refExpr

protected Expr refExpr
The reference expression (produces the object to dispatch on)


methodName

protected java.lang.String methodName
The name of the method


actualList

protected ExprList actualList
The list of actual parameter expressions

Constructor Detail

DispatchExpr

public DispatchExpr(int lineNum,
                    Expr refExpr,
                    java.lang.String methodName,
                    ExprList actualList)
DispatchExpr constructor

Parameters:
lineNum - source line number corresponding to this AST node
refExpr - reference expression (produces the object to dispatch on)
methodName - the name of the method
actualList - list of actual parameter expressions
Method Detail

getRefExpr

public Expr getRefExpr()
Get the reference expression

Returns:
reference expression

getMethodName

public java.lang.String getMethodName()
Get the method name

Returns:
method name

getActualList

public ExprList getActualList()
Get the list of actual parameter expressions

Returns:
actual parameter list

accept

public java.lang.Object accept(visitor.Visitor v,
                               java.lang.Object o)
Visitor method

Specified by:
accept in class Expr
Parameters:
v - visitor object
o - object to pass down
Returns:
result of visiting this node
See Also:
Visitor