public class WhileProgramBlock extends ProgramBlock
_beginColumn, _beginLine, _endColumn, _endLine, _filename, _text, PRED_VAR| Constructor and Description | 
|---|
WhileProgramBlock(Program prog,
                 ArrayList<Instruction> predicate)  | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
addProgramBlock(ProgramBlock childBlock)  | 
void | 
execute(ExecutionContext ec)
Executes this program block (incl recompilation if required). 
 | 
ArrayList<ProgramBlock> | 
getChildBlocks()
Get the list of child program blocks if nested; otherwise this method returns null. 
 | 
ArrayList<Instruction> | 
getPredicate()  | 
boolean | 
isNested()
Indicates if the program block is nested, i.e., if it contains other program blocks (e.g., loops). 
 | 
String | 
printBlockErrorLocation()  | 
void | 
setChildBlocks(ArrayList<ProgramBlock> childs)  | 
void | 
setPredicate(ArrayList<Instruction> predicate)  | 
executePredicate, getBeginColumn, getBeginLine, getEndColumn, getEndLine, getExitInstruction, getFilename, getProgram, getStatementBlock, getText, getThreadID, hasThreadID, isThreadID, setBeginColumn, setBeginLine, setEndColumn, setEndLine, setExitInstruction, setFilename, setParseInfo, setProgram, setStatementBlock, setText, setThreadIDequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitctxAndFilenameToParseInfopublic WhileProgramBlock(Program prog, ArrayList<Instruction> predicate)
public void addProgramBlock(ProgramBlock childBlock)
public ArrayList<Instruction> getPredicate()
public void setPredicate(ArrayList<Instruction> predicate)
public ArrayList<ProgramBlock> getChildBlocks()
ProgramBlockgetChildBlocks in class ProgramBlockpublic boolean isNested()
ProgramBlockisNested in class ProgramBlockpublic void execute(ExecutionContext ec)
ProgramBlockexecute in class ProgramBlockec - execution contextpublic void setChildBlocks(ArrayList<ProgramBlock> childs)
public String printBlockErrorLocation()
printBlockErrorLocation in class ProgramBlockCopyright © 2021 The Apache Software Foundation. All rights reserved.