BaseProtectiveBehaviour

StockSharp.Algo.Strategies.Protective

Base implementation of IProtectiveBehaviour.

继承自: BaseLogReceiver

实现: IProtectiveBehaviour, ILogSource, IDisposable

构造函数

BaseProtectiveBehaviour(Unit, Unit, bool, TimeSpan, TimeSpan, bool)

Initializes a new instance of the BaseProtectiveBehaviour.

takeValue
Take offset.
stopValue
Stop offset.
isStopTrailing
Whether to use a trailing technique.
takeTimeout
Time limit. If protection has not worked by this time, the position will be closed on the market.
stopTimeout
Time limit. If protection has not worked by this time, the position will be closed on the market.
useMarketOrders
Whether to use market orders.

属性

IsStopTrailing : bool

Whether to use a trailing technique.

Position : decimal

Current position value.

StopTimeout : TimeSpan

Time limit. If protection has not worked by this time, the position will be closed on the market.

StopValue : Unit

Stop offset.

TakeTimeout : TimeSpan

Time limit. If protection has not worked by this time, the position will be closed on the market.

TakeValue : Unit

Take offset.

UseMarketOrders : bool

Whether to use market orders.

方法

TryActivate(decimal, DateTime) : ValueTuple?<bool, Sides, decimal, decimal, OrderCondition>

Try activate protection.

price
Current price.
time
Current time.

返回值: Registration order info.

Update(decimal, decimal, DateTime) : ValueTuple?<bool, Sides, decimal, decimal, OrderCondition>

Update position difference.

price
Position difference price.
value
Position difference value.
time
Current time.

返回值: Registration order info.