private void L1OnFundamentalMsg(IQMessageArgs args) { L1FundamentalMsg msg; L1FundamentalMsg.Parse(args, out msg); InstrumentSubscription subscription; using (instrumentSubscriptionsLock.Lock()) { if (!instrumentSubscriptionsByCode.TryGetValue(msg.Symbol, out subscription)) { return; } } switch (subscription.SecurityType) { case SecurityType.FUTURE: case SecurityType.FOPTION: break; default: subscription.InstrumentParams.PriceStepValue = subscription.InstrumentParams.PriceStep; break; } var shouldTransmit = subscription.Update(ref msg); if (shouldTransmit) { OnMessageReceived(subscription.InstrumentParams); } }
public bool Update(ref L1FundamentalMsg msg) { Confirm(); using (syncRoot.Lock()) { InstrumentParams.DecimalPlaces = msg.DecimalPlaces; InstrumentParams.PriceStep = msg.PriceStep; InstrumentParams.PriceStepValue = msg.PriceStepValue; return(true); } }