void updateNode(LiveSystem liveSystem, QNode node) { var childNodes = list <LiveMarketNode>(node.children()); var totalTicks = sum(convert(childNodes, child => child.ticksReceived)); if (totalTicks == 0) { return; } var tickRate = sum(convert(childNodes, child => child.tickRate)); var tickLag = max(convert(childNodes, child => child.tickLag)); node.color = tickLag - 5000; node.size = isEqualSizes_ ? 1 : Math.Max(1F, tickRate); var isDown = exists(childNodes, child => child.isDown); var downText = isDown ? "" : "DOWN "; var lastTickProcessed = max(convert(childNodes, child => child.lastTickProcessed)); node.text = downText + liveSystem.pv().name() + " - " + liveSystem.id() + "\n" + tickRate.ToString("n0") + "/min, " + tickLag + "ms\n" + totalTicks.ToString("n0") + "\n" + lastTickProcessed.ToString("HH:mm:ss") + "\n"; }
public static Email basicTradeEmail(LiveSystem system, Trade trade, int liveOrderId) { return(Email.trade( system.siv().system() + paren(system.pv().name()) + " Filled Order for " + trade.order().symbol.name + " - " + hostname(), "Order (" + liveOrderId + "): " + trade.shortString() + "\nTimestamp: " + ymdHuman(now()) + "\nDescription: " + trade.description )); }
void insertUnknownRow(DataRow row, LiveSystem system) { row.ItemArray = new object[] { system.siv().sivName("-"), system.pv().name(), system.id(), "unknown", -1, "unknown", // "2008/10/09 15:55:07", "unknown", // "2008/10/09 15:55:07", }; table.Rows.InsertAt(row, 0); }