org.nlogo.command
Class Procedure
java.lang.Object
org.nlogo.command.Procedure
public class Procedure
- extends Object
fileName
public final String fileName
name
public String name
pos
public int pos
endPos
public int endPos
args
public List args
type
public final int type
usableBy
public String usableBy
localsCount
public int localsCount
templateVars
public int templateVars
topLevel
public boolean topLevel
owner
public SourceOwner owner
nameToken
public org.nlogo.compiler.Token nameToken
TYPE_COMMAND
public static final int TYPE_COMMAND
- See Also:
- Constant Field Values
TYPE_REPORTER
public static final int TYPE_REPORTER
- See Also:
- Constant Field Values
lets
public final List lets
code
public Command[] code
Procedure
public Procedure(String fileName,
int type)
getNumSlots
public int getNumSlots()
- returns the total number of slots this procedure requires in an
Activation. It's basically the arity of the procedure plus
the number of local vars plus the number of unique (i.e., nested)
template vars.
getSyntax
public org.nlogo.compiler.Syntax getSyntax()
getNameAndFile
public String getNameAndFile()
toString
public String toString()
- Overrides:
toString
in class Object
dump
public String dump()
init
public void init(Workspace workspace)
getLetFromArg
public Let getLetFromArg(String ident,
int tokPos)