Interface ExecutionCallback
- All Known Implementing Classes:
AbstractExecutionCallback, DefaultExecutionCallback
public interface ExecutionCallback
Strategy's callback with execution results
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ExecutionCallbackA no-op callback that silently ignores all execution events. -
Method Summary
Modifier and TypeMethodDescriptionvoidonComplete(ExecutionResult enterResult, ExecutionResult exitResult, Amount yieldAmount) onFailedBuy(ExecutionResult result) onFailedSell(ExecutionResult result) voidonFilledBuy(ExecutionResult result) voidonFilledSell(ExecutionResult result) onPartialBuy(ExecutionResult result) onPartialSell(ExecutionResult result) default voidonPositionUpdated(PositionSnapshot position) default voidonStopLossCancelled(Instrument instrument) Called when an active stop-loss order has been cancelled (e.g., before a manual sell).default voidonStopLossPlaced(Instrument instrument, String orderId, BigDecimal stopPrice) Called when a stop-loss order has been successfully placed on the exchange.default voidonStopLossTriggered(Instrument instrument, ExecutionResult exitResult) Called when a stop-loss order has been triggered (filled) by the exchange.
-
Field Details
-
NOOP
A no-op callback that silently ignores all execution events.
-
-
Method Details
-
onFilledBuy
-
onFilledSell
-
onComplete
-
onPartialBuy
-
onFailedBuy
-
onPartialSell
-
onFailedSell
-
onPositionUpdated
-
onStopLossPlaced
Called when a stop-loss order has been successfully placed on the exchange. -
onStopLossTriggered
Called when a stop-loss order has been triggered (filled) by the exchange. -
onStopLossCancelled
Called when an active stop-loss order has been cancelled (e.g., before a manual sell).
-