Class TimeFrameStrategy
- Namespace
- StockSharp.Algo.Strategies
- Assembly
- StockSharp.Algo.dll
The timeframe based trade strategy.
public abstract class TimeFrameStrategy : Strategy, IPersistable, INotifyPropertyChangedEx, INotifyPropertyChanged, IMarketRuleContainer, ILogReceiver, ILogSource, IDisposable, ICloneable<Strategy>, ICloneable, IMarketDataProvider, ISubscriptionProvider, ISecurityProvider, ISecurityMessageProvider, ITransactionProvider, IPositionProvider, IPortfolioProvider, IScheduledTask
- Inheritance
-
TimeFrameStrategy
- Implements
-
IPersistableINotifyPropertyChangedExICloneable<Strategy>
- Inherited Members
- Extension Methods
Constructors
TimeFrameStrategy(TimeSpan)
Initialize TimeFrameStrategy.
protected TimeFrameStrategy(TimeSpan timeFrame)
Parameters
timeFrame
TimeSpanThe strategy timeframe.
Properties
Interval
The strategy start-up interval. By default, it equals to TimeFrame.
public TimeSpan Interval { get; set; }
Property Value
TimeFrame
The strategy timeframe.
public TimeSpan TimeFrame { get; set; }
Property Value
Methods
OnProcess()
The implementation of the trade algorithm.
protected abstract ProcessResults OnProcess()
Returns
- ProcessResults
The result of trade algorithm one iteration operation.
OnStarted(DateTimeOffset)
The method is called when the Start() method has been called and the ProcessState state has been taken the Started value.
protected override void OnStarted(DateTimeOffset time)
Parameters
time
DateTimeOffset