void HandlePricingServiceClientPriceUpdate(object sender, MarketPriceEventArgs eventArgs) { var subscriptionKey = eventArgs.CurrencyPair; MarketPriceViewModel marketPriceViewModel; if (_currencyToMarketPriceViewModel.TryGetValue(subscriptionKey, out marketPriceViewModel)) { marketPriceViewModel.Update(eventArgs); } //else.. log unexpected price }
public void Update(MarketPriceEventArgs eventArgs) { Bid.Update(eventArgs.MarketPrice.BidPrice); Ask.Update(eventArgs.MarketPrice.AskPrice); }