org.holtz.zoe.zoel
Class StatementList
java.lang.Object
org.holtz.zoe.zoel.Expression
org.holtz.zoe.zoel.StatementList
public class StatementList
- extends Expression
A list of Statements
of a Bug
, constituting a block statement in a Zoel
program.
- Author:
- Brian Holtz
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
statements
public java.util.ArrayList<Statement> statements
StatementList
public StatementList()
StatementList
public StatementList(java.util.Random random,
int maxStatements)
StatementList
public StatementList(java.util.ArrayList<Statement> statements2Copy)
StatementList
public StatementList(StatementList theStatements)
StatementList
public StatementList(StatementList mom,
StatementList dad,
java.util.Random random)
copy
public StatementList copy()
- Specified by:
copy
in class Expression
add
public StatementList add(Statement statement)
totalStatements
public int totalStatements()
- Overrides:
totalStatements
in class Expression
nthStatement
public StatementListCall nthStatement(java.lang.Integer[] nth)
- Overrides:
nthStatement
in class Expression
randomPosition
public StatementListCall randomPosition(java.util.Random random)
mutate
public Statement mutate(int nth,
java.util.Random random)
toString
public java.lang.String toString()
- Specified by:
toString
in class Expression
toString
public java.lang.String toString(java.lang.String separator)
toString
public java.lang.String toString(java.lang.String stmtSeparator,
Expression currExpr,
java.lang.String cursor)
- Specified by:
toString
in class Expression
parse
public static StatementList parse(ZoelTokenizer zoelTokenizer)
throws java.lang.Exception
- Throws:
java.lang.Exception