/*
PseudoCode Interpreted Language (PCIL): Part of the algoviz@vt collection of algorithm visualizations.
Copyright (C) 2008 Brandon Malone, Frank Hadlock
This file is part of the PseudoCode Interpreted Language.
PseudoCode Interpreted Language is free software: you can redistribute
it and/or modify it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3 of the License,
or (at your option) any later version.
PseudoCode Interpreted Language is distributed in the hope that it will
be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
Public License for more details.
You should have received a copy of the GNU General Public License along with
PseudoCode Interpreted Language. If not, see
.
*/
/*
* Function.java
*
* Created on March 3, 2008, 6:58 PM
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/
package syntacticanalysis;
import dynamicmvc.Primitive;
import dynamicmvc.PrimitiveFactory;
import java.util.ArrayList;
/**
*
* @author Brandon
*/
public class Function {
private String name;
private int address; // skip past the declaration
// this should be the actual first "instruction"
private ArrayList parameterList;
/** Creates a new instance of Function */
public Function(String name, int address, ArrayList parameterList) {
this.setName(name);
this.setAddress(address);
this.setParameterList(parameterList);
}
public void addParameter(Primitive parameter) {
getParameterList().add(parameter);
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public int getAddress() {
return address;
}
public void setAddress(int address) {
this.address = address;
}
public ArrayList getParameterList() {
return parameterList;
}
public void setParameterList(ArrayList parameterList) {
this.parameterList = parameterList;
}
}