public void ScanInstructionGroup(NodeRuntimeApplication rta, NodeInstructionGroup instructionGroup) { var contextIterator = new InstructionGroupExecutorContextLD(true); // rung condition at the beginning of a rung is always true // A rung only ever has one series instruction as a child, so the foreach is kind of overkill, but should work foreach (var instruction in instructionGroup.NodeInstructionChildren) { contextIterator = ScanInstruction(rta, instruction, contextIterator); } }
public InstructionGroupExecutorContextLD ScanInstruction(NodeRuntimeApplication rta, NodeInstruction instruction, InstructionGroupExecutorContextLD context) { var retVal = new InstructionGroupExecutorContextLD(false); if (m_instructionExecutors.ContainsKey(instruction.InstructionType)) { var executor = m_instructionExecutors[instruction.InstructionType]; retVal = executor.ScanInstruction(rta, instruction, context); } else { // FIXME - throw some kind of exception? } return(retVal); }
public InstructionGroupExecutorContextLD ScanInstruction(NodeRuntimeApplication rta, NodeInstruction instruction, InstructionGroupExecutorContextLD context) { var retVal = new InstructionGroupExecutorContextLD(false); if (m_instructionExecutors.ContainsKey(instruction.InstructionType)) { var executor = m_instructionExecutors[instruction.InstructionType]; retVal = executor.ScanInstruction(rta, instruction, context); } else { // FIXME - throw some kind of exception? } return retVal; }
public void ScanInstructionGroup(NodeRuntimeApplication rta, NodeInstructionGroup instructionGroup) { var contextIterator = new InstructionGroupExecutorContextLD(true); // rung condition at the beginning of a rung is always true // A rung only ever has one series instruction as a child, so the foreach is kind of overkill, but should work foreach (var instruction in instructionGroup.NodeInstructionChildren) { contextIterator = ScanInstruction(rta, instruction, contextIterator); } }