ast
Class Program
java.lang.Object
ast.ASTNode
ast.Program
public class Program
- extends ASTNode
The Program class represents an entire program, which
consists of a list of classes (classList).
- See Also:
ASTNode
,
ClassList
Field Summary |
protected ClassList |
classList
List of class declarations that comprise the program |
Constructor Summary |
Program(int lineNum,
ClassList classList)
Program constructor |
Method Summary |
java.lang.Object |
accept(visitor.Visitor v,
java.lang.Object o)
Visitor method |
ClassList |
getClassList()
Get list of classes that comprise the program |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
classList
protected ClassList classList
- List of class declarations that comprise the program
Program
public Program(int lineNum,
ClassList classList)
- Program constructor
- Parameters:
lineNum
- source line number corresponding to this AST nodeclassList
- list of class declarations
getClassList
public ClassList getClassList()
- Get list of classes that comprise the program
- Returns:
- list of class declarations
accept
public java.lang.Object accept(visitor.Visitor v,
java.lang.Object o)
- Visitor method
- Specified by:
accept
in class ASTNode
- Parameters:
v
- visitor objecto
- object to pass down
- Returns:
- result of visiting this node
- See Also:
Visitor