17 using System.Collections.Generic;
34 private readonly
Symbol _symbol;
35 private readonly Func<DateTime, IEnumerable<string>> _selector;
37 private readonly TimeSpan _interval;
76 _universeSettings = universeSettings;
77 _symbol =
Symbol.
Create($
"{name}-{securityType}-{market}", securityType, market);
94 selector.ConvertToDelegate<Func<DateTime, object>>().ConvertToUniverseSelectionStringDelegate(),
108 var entry = MarketHours.GetEntry(_symbol.ID.Market, (
string)
null, _symbol.SecurityType);
113 universeSettings.Resolution,
115 entry.ExchangeHours.TimeZone,
116 universeSettings.FillForward,
117 universeSettings.ExtendedMarketHours,
121 yield
return new CustomUniverse(config, universeSettings, _interval, dt =>
Select(algorithm, dt));
132 if (_selector ==
null)
134 throw new ArgumentNullException(nameof(_selector));
137 return _selector(date);
143 public override string ToString() => _symbol.Value;