public class ASTFunction extends ASTNode
Modifier and Type | Class and Description |
---|---|
static class |
ASTFunction.Parameter
Decaf formal parameter (name and data type).
|
ASTNode.DataType
Modifier and Type | Field and Description |
---|---|
ASTBlock |
body |
String |
name |
List<ASTFunction.Parameter> |
parameters |
ASTNode.DataType |
returnType |
attributes
Constructor and Description |
---|
ASTFunction(String name,
ASTNode.DataType returnType,
ASTBlock body) |
Modifier and Type | Method and Description |
---|---|
String |
getParameterStr() |
void |
traverse(ASTVisitor visitor)
Generic traversal method for the visitor pattern.
|
getASTTypeStr, getDepth, getParent, getSourceInfo, getType, setDepth, setParent, setSourceInfo, setType, typeToString
public String name
public ASTNode.DataType returnType
public ASTBlock body
public List<ASTFunction.Parameter> parameters
public ASTFunction(String name, ASTNode.DataType returnType, ASTBlock body)
public String getParameterStr()
public void traverse(ASTVisitor visitor)
ASTNode
Copyright © 2019. All rights reserved.