예제 #1
0
 public void Dispose()
 {
     OhlcMaker.OnOhlcMaked -= OhlcMaker_OnOhlcMaked;
     if (ohlcSaver != null)
     {
         ohlcSaver.Dispose(); ohlcSaver = null;
     }
 }
예제 #2
0
        public KlineSvc(IOptionModel Model)
        {
            this.Model = Model;

            ohlcGen   = new OhlcGenarator();
            ohlcSaver = new OhlcSaver();
            kdp       = new KlineDataPool((cid) =>
            {
                return(Model.Contracts.Where(a => a.Id == cid && a.IsDel == false).FirstOrDefault());
            });
        }