public new void Process() { string node = NodeNumber(); OAINodeModel model = OAINodeController.Relay().Peek(node); bool exists = true; if (null == model) { exists = false; model = new OAINodeModel(); } model.Node = node; model.Status = LinkStatus(); model.State = ReasonCode(); if (!exists) { OAINodeController.Relay().Push(node, model); } }
public new void Process() { OAINoOperation cmd = (OAINoOperation)Cmd; if (null == cmd) { return; } // Command failed if (0 != Outcome()) { return; } // Update the status of all the nodes for (int i = 0; i < NumNodes(); i++) { string node = NodeNumber(i); OAINodeModel model = OAINodeController.Relay().Peek(node); bool exists = true; if (null == model) { exists = false; model = new OAINodeModel(); } model.Node = node; model.Status = NodeStatus(i); if (!exists) { OAINodeController.Relay().Push(node, model); } } }