예제 #1
0
 private void ReplaceSLTPOrders(OrderData orderData, AccountSymbolKey positionKey)
 {
     CancelUnfilledOrdersForPosition(positionKey);
     PlaceSLTPOrders(orderData);
 }
예제 #2
0
 /// <summary>
 /// removes TakeProfit and StopLoss target orders only
 /// </summary>
 private void CancelUnfilledOrdersForPosition(AccountSymbolKey positionKey)
 {
     _orders[positionKey]?.RemoveAll(r => r.PositionKey?.Equals(positionKey) ?? false);
 }