public class FunctionProgramBlock extends ProgramBlock implements Types.FunctionBlock
Modifier and Type | Field and Description |
---|---|
String |
_functionName |
String |
_namespace |
_beginColumn, _beginLine, _endColumn, _endLine, _filename, _text, PRED_VAR
Constructor and Description |
---|
FunctionProgramBlock(Program prog,
List<DataIdentifier> inputParams,
List<DataIdentifier> outputParams) |
Modifier and Type | Method and Description |
---|---|
void |
addProgramBlock(ProgramBlock childBlock) |
Types.FunctionBlock |
cloneFunctionBlock() |
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.
|
DataIdentifier |
getInputParam(String name) |
List<String> |
getInputParamNames() |
ArrayList<DataIdentifier> |
getInputParams() |
ArrayList<DataIdentifier> |
getOutputParams() |
boolean |
isNested()
Indicates if the program block is nested, i.e.,
if it contains other program blocks (e.g., loops).
|
boolean |
isNondeterministic() |
boolean |
isRecompileOnce() |
String |
printBlockErrorLocation() |
void |
setChildBlocks(ArrayList<ProgramBlock> pbs) |
void |
setNondeterministic(boolean flag) |
void |
setRecompileOnce(boolean flag) |
executePredicate, getBeginColumn, getBeginLine, getEndColumn, getEndLine, getExitInstruction, getFilename, getProgram, getStatementBlock, getText, getThreadID, hasThreadID, isThreadID, setBeginColumn, setBeginLine, setEndColumn, setEndLine, setExitInstruction, setFilename, setParseInfo, setProgram, setStatementBlock, setText, setThreadID
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
ctxAndFilenameToParseInfo
public FunctionProgramBlock(Program prog, List<DataIdentifier> inputParams, List<DataIdentifier> outputParams)
public DataIdentifier getInputParam(String name)
public ArrayList<DataIdentifier> getInputParams()
public ArrayList<DataIdentifier> getOutputParams()
public void addProgramBlock(ProgramBlock childBlock)
public void setChildBlocks(ArrayList<ProgramBlock> pbs)
public ArrayList<ProgramBlock> getChildBlocks()
ProgramBlock
getChildBlocks
in class ProgramBlock
public boolean isNested()
ProgramBlock
isNested
in class ProgramBlock
public void execute(ExecutionContext ec)
ProgramBlock
execute
in class ProgramBlock
ec
- execution contextpublic void setRecompileOnce(boolean flag)
public boolean isRecompileOnce()
public void setNondeterministic(boolean flag)
public boolean isNondeterministic()
public Types.FunctionBlock cloneFunctionBlock()
cloneFunctionBlock
in interface Types.FunctionBlock
public String printBlockErrorLocation()
printBlockErrorLocation
in class ProgramBlock
Copyright © 2020 The Apache Software Foundation. All rights reserved.