private void OnNewFundamental(object sender, FundamentalEventArgs args) { if (this.HandleMarketData(args.Provider, args.Instrument)) { this.metaStrategyBase.SetNewFundamental(args); } }
internal void EmitNewFundamental(FundamentalEventArgs e) { this.Fundamental = e.Fundamental; if (this.NewFundamental != null) { this.NewFundamental(this, e); } }
private static void OnNewFundamental(object sender, FundamentalEventArgs e) { Instrument instrument = e.Instrument as Instrument ?? InstrumentManager.Instruments[e.Instrument.Symbol, e.Provider.Name]; if (instrument == null) { return; } FundamentalArray array = DataManager.fundamentalArrayList[instrument]; array.Add(e.Fundamental); if (DataManager.fundamentalArrayLength != -1 && array.Count > DataManager.fundamentalArrayLength) { array.RemoveAt(0); } instrument.EmitNewFundamental(e); }
internal void EmitFundamental(object o, FundamentalMessageEventArgs args) { if (null != NewFundamental) { string sSymbol = args.Message.items[1]; IQFeedDataRequestRecord rr = htL1WatchedSymbols[sSymbol] as IQFeedDataRequestRecord; FundamentalEventArgs f = new FundamentalEventArgs(new Fundamental(), rr.instrument, this); try { if ("" != args.Message.items[10]) { f.Fundamental.EarningsPerShare = Convert.ToDouble(args.Message.items[10]); } } catch { } NewFundamental(this, f); } }