Пример #1
0
        public Bar(DateTime time, Timeframes tf)
            : this()
        {
            var dates = TfHelper.GetDates(time, tf);

            this.Time        = dates[0];
            this.NextBarTime = dates[1];
        }
Пример #2
0
 /// <summary>
 /// Add new time interval.
 /// </summary>
 /// <param name="date">Start time</param>
 /// <param name="tf">Timeframe</param>
 public void Add(DateTime date, Timeframes tf)
 {
     DateTime[] dts = TfHelper.GetDates(date, tf);
     _dates.Add(new BarDate(dts[0], dts[1]));
 }