Beispiel #1
0
 public StrategyDataFrame(string strategyIdentityCode, int frameSize, PricebarCache pricebarCache)
 {
     this.pricebarCache = pricebarCache;
     this.frameSize     = frameSize;
     this.barType       = pricebarCache.BarType;
     this.cacheId       = pricebarCache.CacheId;
     this.strategyCache = new StrategyCache(strategyIdentityCode, this.barType, this.cacheId);
 }
Beispiel #2
0
        public SignalCacheNavigator(string cacheFolder, BarItemType barType, Guid cacheId, string signalIdentityCode)
        {
            this.signalCache   = new SignalCache(signalIdentityCode, barType, cacheId);
            this.pricebarCache = new PricebarCache(barType, cacheId, CacheModeOption.Read);

            this.barType = barType;
            this.cacheId = cacheId;

            CacheHeaderInfo headerInfo = this.signalCache.Header;

            foreach (KeyValuePair <string, string> extendedProperty in headerInfo.ExtendedProperties)
            {
                switch (extendedProperty.Key)
                {
                case "Indicators":
                    indicatorCacheList = CacheHelper.LoadIndicatorCacheList(extendedProperty.Value, barType, cacheId);
                    break;
                }
            }

            InitializeSignalDataFrame();
        }