Class FunctionProgramBlock
- java.lang.Object
- 
- org.apache.sysds.runtime.controlprogram.ProgramBlock
- 
- org.apache.sysds.runtime.controlprogram.FunctionProgramBlock
 
 
- 
- All Implemented Interfaces:
- Types.FunctionBlock,- ParseInfo
 
 public class FunctionProgramBlock extends ProgramBlock implements Types.FunctionBlock 
- 
- 
Field SummaryFields Modifier and Type Field Description String_functionNameString_namespace- 
Fields inherited from class org.apache.sysds.runtime.controlprogram.ProgramBlock_beginColumn, _beginLine, _endColumn, _endLine, _filename, _text, PRED_VAR
 
- 
 - 
Constructor SummaryConstructors Constructor Description FunctionProgramBlock(Program prog, List<DataIdentifier> inputParams, List<DataIdentifier> outputParams)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddProgramBlock(ProgramBlock childBlock)Types.FunctionBlockcloneFunctionBlock()voidexecute(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.DataIdentifiergetInputParam(String name)List<String>getInputParamNames()ArrayList<DataIdentifier>getInputParams()List<String>getOutputParamNames()ArrayList<DataIdentifier>getOutputParams()booleanisNested()Indicates if the program block is nested, i.e., if it contains other program blocks (e.g., loops).booleanisNondeterministic()booleanisRecompileOnce()StringprintBlockErrorLocation()voidsetChildBlocks(ArrayList<ProgramBlock> pbs)voidsetNondeterministic(boolean flag)voidsetRecompileOnce(boolean flag)- 
Methods inherited from class org.apache.sysds.runtime.controlprogram.ProgramBlockexecutePredicate, getBeginColumn, getBeginLine, getEndColumn, getEndLine, getExitInstruction, getFilename, getProgram, getStatementBlock, getText, getThreadID, hasThreadID, isThreadID, setBeginColumn, setBeginLine, setEndColumn, setEndLine, setExitInstruction, setFilename, setParseInfo, setProgram, setStatementBlock, setText, setThreadID
 
- 
 
- 
- 
- 
Constructor Detail- 
FunctionProgramBlockpublic FunctionProgramBlock(Program prog, List<DataIdentifier> inputParams, List<DataIdentifier> outputParams) 
 
- 
 - 
Method Detail- 
getInputParampublic DataIdentifier getInputParam(String name) 
 - 
getInputParamspublic ArrayList<DataIdentifier> getInputParams() 
 - 
getOutputParamspublic ArrayList<DataIdentifier> getOutputParams() 
 - 
addProgramBlockpublic void addProgramBlock(ProgramBlock childBlock) 
 - 
setChildBlockspublic void setChildBlocks(ArrayList<ProgramBlock> pbs) 
 - 
getChildBlockspublic ArrayList<ProgramBlock> getChildBlocks() Description copied from class:ProgramBlockGet the list of child program blocks if nested; otherwise this method returns null.- Specified by:
- getChildBlocksin class- ProgramBlock
- Returns:
- list of program blocks
 
 - 
isNestedpublic boolean isNested() Description copied from class:ProgramBlockIndicates if the program block is nested, i.e., if it contains other program blocks (e.g., loops).- Specified by:
- isNestedin class- ProgramBlock
- Returns:
- true if nested
 
 - 
executepublic void execute(ExecutionContext ec) Description copied from class:ProgramBlockExecutes this program block (incl recompilation if required).- Specified by:
- executein class- ProgramBlock
- Parameters:
- ec- execution context
 
 - 
setRecompileOncepublic void setRecompileOnce(boolean flag) 
 - 
isRecompileOncepublic boolean isRecompileOnce() 
 - 
setNondeterministicpublic void setNondeterministic(boolean flag) 
 - 
isNondeterministicpublic boolean isNondeterministic() 
 - 
cloneFunctionBlockpublic Types.FunctionBlock cloneFunctionBlock() - Specified by:
- cloneFunctionBlockin interface- Types.FunctionBlock
 
 - 
printBlockErrorLocationpublic String printBlockErrorLocation() - Overrides:
- printBlockErrorLocationin class- ProgramBlock
 
 
- 
 
-