Пример #1
0
 /// <summary>
 /// To start backtesing.
 /// </summary>
 /// <param name="backtest">Backtesting session.</param>
 public void StartBacktest(StrategyBacktest backtest)
 {
     backtest.Id = Invoke(f => f.StartBacktest(SessionId, backtest));
     _backtests.Add(backtest.Id, backtest);
     _startedBacktests.Add(backtest, 0);
 }
Пример #2
0
 /// <summary>
 /// To stop the backtesing.
 /// </summary>
 /// <param name="backtest">Backtesting session.</param>
 public void StopBacktest(StrategyBacktest backtest)
 {
     ValidateError(Invoke(f => f.StopBacktest(SessionId, backtest.Id)));
 }
Пример #3
0
 /// <summary>
 /// To get an approximate of money to spend for the specified backtesting configuration.
 /// </summary>
 /// <param name="backtest">Backtesting session.</param>
 /// <returns>An approximate of money.</returns>
 public decimal GetApproximateAmount(StrategyBacktest backtest)
 {
     return(Invoke(f => f.GetApproximateAmount(SessionId, backtest)));
 }