Class AmendTrade
- All Implemented Interfaces:
RFSCoreTrade
A single AmendTrade active in the system.
A Trade is initiated by a client and is tied to a TradeChannel. The lifecycle of a Trade consists
of a number of messages, represented by TradeEvents, being sent between the client and the
Trading System in both directions. These messages cause the Trade to transition between a number
of predefined states.
Trades are comprised of one or more trade legs, which each leg representing the exchange of a financial instrument and the resultant cash flow. It is possible to add, remove and update trades from the client or from the TradingDataSource.
A Trade is uniquely identified in two ways: by RequestId set by the client and a TradeId set by the Trading System.
-
Constructor Summary
ConstructorsConstructorDescriptionAmendTrade(@NotNull com.caplin.trading.Trade backingTrade, @NotNull ScheduledExecutorService executorService) Constructor used by the generated code. -
Method Summary
Modifier and TypeMethodDescription@NotNull AcceptWarningAckTradeEventCreate aTradeEventthat can be passed toto trigger the AcceptWarningAck transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull ClientCloseAckTradeEventCreate aTradeEventthat can be passed toto trigger the ClientCloseAck transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull DetailsUpdateTradeEventCreate aTradeEventthat can be passed toto trigger the DetailsUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull DetailsUpdateTradeEventcreateDetailsUpdateTradeEvent(@NotNull Message message) Create aTradeEventthat can be passed toto trigger the DetailsUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull ErrorTradeEventCreate aTradeEventthat can be passed toto trigger the Error transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull ExecuteAckTradeEventCreate aTradeEventthat can be passed toto trigger the ExecuteAck transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull ExpireTradeEventCreate aTradeEventthat can be passed toto trigger the Expire transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull HoldTradeEventCreate aTradeEventthat can be passed toto trigger the Hold transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull PickUpTradeEventCreate aTradeEventthat can be passed toto trigger the PickUp transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull PriceUpdateTradeEventCreate aTradeEventthat can be passed toto trigger the PriceUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull PriceUpdateTradeEventcreatePriceUpdateTradeEvent(@NotNull Message message) Create aTradeEventthat can be passed toto trigger the PriceUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull RejectTradeEventCreate aTradeEventthat can be passed toto trigger the Reject transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull SubmitAckTradeEventCreate aTradeEventthat can be passed toto trigger the SubmitAck transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull TradeConfirmationTradeEventCreate aTradeEventthat can be passed toto trigger the TradeConfirmation transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull TradeConfirmationTradeEventcreateTradeConfirmationTradeEvent(@NotNull Message message) Create aTradeEventthat can be passed toto trigger the TradeConfirmation transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull WarningTradeEventCreate aTradeEventthat can be passed toto trigger the Warning transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull WarningTradeEventcreateWarningTradeEvent(@NotNull Message message) Create aTradeEventthat can be passed toto trigger the Warning transition in the trade model of the adapter and client applicationTrade.sendEvent@NotNull WithdrawTradeEventCreate aTradeEventthat can be passed toto trigger the Withdraw transition in the trade model of the adapter and client applicationTrade.sendEventvoidSend aTradeEventwith no fields to trigger the AcceptWarningAck transition in the trade model of the adapter and client applicationvoidsendAcceptWarningAckEvent(@NotNull AcceptWarningAckTradeEvent event) Send aTradeEventto trigger the AcceptWarningAck transition in the trade model of the adapter and client applicationvoidSend aTradeEventwith no fields to trigger the ClientCloseAck transition in the trade model of the adapter and client applicationvoidsendClientCloseAckEvent(@NotNull ClientCloseAckTradeEvent event) Send aTradeEventto trigger the ClientCloseAck transition in the trade model of the adapter and client applicationvoidsendDetailsUpdateEvent(@NotNull DetailsUpdateTradeEvent event) Send aTradeEventto trigger the DetailsUpdate transition in the trade model of the adapter and client applicationvoidsendDetailsUpdateEvent(@NotNull Message message) Send aTradeEventto trigger the DetailsUpdate transition in the trade model of the adapter and client applicationvoidsendErrorEvent(@NotNull ErrorTradeEvent event) Send aTradeEventto trigger the Error transition in the trade model of the adapter and client applicationvoidSend aTradeEventwith no fields to trigger the ExecuteAck transition in the trade model of the adapter and client applicationvoidsendExecuteAckEvent(@NotNull ExecuteAckTradeEvent event) Send aTradeEventto trigger the ExecuteAck transition in the trade model of the adapter and client applicationvoidSend aTradeEventwith no fields to trigger the Expire transition in the trade model of the adapter and client applicationvoidsendExpireEvent(@NotNull ExpireTradeEvent event) Send aTradeEventto trigger the Expire transition in the trade model of the adapter and client applicationvoidSend aTradeEventwith no fields to trigger the Hold transition in the trade model of the adapter and client applicationvoidsendHoldEvent(@NotNull HoldTradeEvent event) Send aTradeEventto trigger the Hold transition in the trade model of the adapter and client applicationvoidSend aTradeEventwith no fields to trigger the PickUp transition in the trade model of the adapter and client applicationvoidsendPickUpEvent(@NotNull PickUpTradeEvent event) Send aTradeEventto trigger the PickUp transition in the trade model of the adapter and client applicationvoidsendPriceUpdateEvent(@NotNull PriceUpdateTradeEvent event) Send aTradeEventto trigger the PriceUpdate transition in the trade model of the adapter and client applicationvoidsendPriceUpdateEvent(@NotNull Message message) Send aTradeEventto trigger the PriceUpdate transition in the trade model of the adapter and client applicationvoidsendRejectEvent(@NotNull RejectTradeEvent event) Send aTradeEventto trigger the Reject transition in the trade model of the adapter and client applicationvoidSend aTradeEventwith no fields to trigger the SubmitAck transition in the trade model of the adapter and client applicationvoidsendSubmitAckEvent(@NotNull SubmitAckTradeEvent event) Send aTradeEventto trigger the SubmitAck transition in the trade model of the adapter and client applicationvoidsendTradeConfirmationEvent(@NotNull TradeConfirmationTradeEvent event) Send aTradeEventto trigger the TradeConfirmation transition in the trade model of the adapter and client applicationvoidsendTradeConfirmationEvent(@NotNull Message message) Send aTradeEventto trigger the TradeConfirmation transition in the trade model of the adapter and client applicationvoidsendWarningEvent(@NotNull WarningTradeEvent event) Send aTradeEventto trigger the Warning transition in the trade model of the adapter and client applicationvoidsendWarningEvent(@NotNull Message message) Send aTradeEventto trigger the Warning transition in the trade model of the adapter and client applicationvoidSend aTradeEventwith no fields to trigger the Withdraw transition in the trade model of the adapter and client applicationvoidsendWithdrawEvent(@NotNull WithdrawTradeEvent event) Send aTradeEventto trigger the Withdraw transition in the trade model of the adapter and client applicationMethods inherited from class com.caplin.motif.UserTrade
getBackingTrade, getExecutorService, getRequestID, getUsername, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.caplin.generated.motif.fx.trading.rfscore.RFSCoreTrade
getBackingTrade, getRequestID, getUsername
-
Constructor Details
-
AmendTrade
public AmendTrade(@NotNull @NotNull com.caplin.trading.Trade backingTrade, @NotNull @NotNull ScheduledExecutorService executorService) Constructor used by the generated code.
- Parameters:
backingTrade- To be used for the parent constructorexecutorService- To be used for the parent constructor (What service is going execute the backingTrade)
-
-
Method Details
-
createErrorTradeEvent
Create a
TradeEventthat can be passed toto trigger the Error transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createErrorTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of ErrorTradeEvent.
-
sendErrorEvent
Send a
TradeEventto trigger the Error transition in the trade model of the adapter and client application- Specified by:
sendErrorEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
createSubmitAckTradeEvent
Create a
TradeEventthat can be passed toto trigger the SubmitAck transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createSubmitAckTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of SubmitAckTradeEvent.
-
sendSubmitAckEvent
Send a
TradeEventto trigger the SubmitAck transition in the trade model of the adapter and client application- Specified by:
sendSubmitAckEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendSubmitAckEvent
public void sendSubmitAckEvent()Send a
TradeEventwith no fields to trigger the SubmitAck transition in the trade model of the adapter and client application- Specified by:
sendSubmitAckEventin interfaceRFSCoreTrade
-
createRejectTradeEvent
Create a
TradeEventthat can be passed toto trigger the Reject transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createRejectTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of RejectTradeEvent.
-
sendRejectEvent
Send a
TradeEventto trigger the Reject transition in the trade model of the adapter and client application- Specified by:
sendRejectEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
createClientCloseAckTradeEvent
Create a
TradeEventthat can be passed toto trigger the ClientCloseAck transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createClientCloseAckTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of ClientCloseAckTradeEvent.
-
sendClientCloseAckEvent
Send a
TradeEventto trigger the ClientCloseAck transition in the trade model of the adapter and client application- Specified by:
sendClientCloseAckEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendClientCloseAckEvent
public void sendClientCloseAckEvent()Send a
TradeEventwith no fields to trigger the ClientCloseAck transition in the trade model of the adapter and client application- Specified by:
sendClientCloseAckEventin interfaceRFSCoreTrade
-
createExpireTradeEvent
Create a
TradeEventthat can be passed toto trigger the Expire transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createExpireTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of ExpireTradeEvent.
-
sendExpireEvent
Send a
TradeEventto trigger the Expire transition in the trade model of the adapter and client application- Specified by:
sendExpireEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendExpireEvent
public void sendExpireEvent()Send a
TradeEventwith no fields to trigger the Expire transition in the trade model of the adapter and client application- Specified by:
sendExpireEventin interfaceRFSCoreTrade
-
createWithdrawTradeEvent
Create a
TradeEventthat can be passed toto trigger the Withdraw transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createWithdrawTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of WithdrawTradeEvent.
-
sendWithdrawEvent
Send a
TradeEventto trigger the Withdraw transition in the trade model of the adapter and client application- Specified by:
sendWithdrawEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendWithdrawEvent
public void sendWithdrawEvent()Send a
TradeEventwith no fields to trigger the Withdraw transition in the trade model of the adapter and client application- Specified by:
sendWithdrawEventin interfaceRFSCoreTrade
-
createExecuteAckTradeEvent
Create a
TradeEventthat can be passed toto trigger the ExecuteAck transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createExecuteAckTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of ExecuteAckTradeEvent.
-
sendExecuteAckEvent
Send a
TradeEventto trigger the ExecuteAck transition in the trade model of the adapter and client application- Specified by:
sendExecuteAckEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendExecuteAckEvent
public void sendExecuteAckEvent()Send a
TradeEventwith no fields to trigger the ExecuteAck transition in the trade model of the adapter and client application- Specified by:
sendExecuteAckEventin interfaceRFSCoreTrade
-
createPriceUpdateTradeEvent
Create a
TradeEventthat can be passed toto trigger the PriceUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createPriceUpdateTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of PriceUpdateTradeEvent.
-
sendPriceUpdateEvent
Send a
TradeEventto trigger the PriceUpdate transition in the trade model of the adapter and client application- Specified by:
sendPriceUpdateEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendPriceUpdateEvent
Send a
TradeEventto trigger the PriceUpdate transition in the trade model of the adapter and client application- Parameters:
message- The message to send.
-
createPriceUpdateTradeEvent
@NotNull public @NotNull PriceUpdateTradeEvent createPriceUpdateTradeEvent(@NotNull @NotNull Message message) Create a
TradeEventthat can be passed toto trigger the PriceUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createPriceUpdateTradeEventin interfaceRFSCoreTrade- Parameters:
message- a Message to be passed to the TradeEvent- Returns:
- A new instance of PriceUpdateTradeEvent.
-
createWarningTradeEvent
Create a
TradeEventthat can be passed toto trigger the Warning transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createWarningTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of WarningTradeEvent.
-
sendWarningEvent
Send a
TradeEventto trigger the Warning transition in the trade model of the adapter and client application- Specified by:
sendWarningEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendWarningEvent
Send a
TradeEventto trigger the Warning transition in the trade model of the adapter and client application- Parameters:
message- The message to send.
-
createWarningTradeEvent
@NotNull public @NotNull WarningTradeEvent createWarningTradeEvent(@NotNull @NotNull Message message) Create a
TradeEventthat can be passed toto trigger the Warning transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createWarningTradeEventin interfaceRFSCoreTrade- Parameters:
message- a Message to be passed to the TradeEvent- Returns:
- A new instance of WarningTradeEvent.
-
createHoldTradeEvent
Create a
TradeEventthat can be passed toto trigger the Hold transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createHoldTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of HoldTradeEvent.
-
sendHoldEvent
Send a
TradeEventto trigger the Hold transition in the trade model of the adapter and client application- Specified by:
sendHoldEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendHoldEvent
public void sendHoldEvent()Send a
TradeEventwith no fields to trigger the Hold transition in the trade model of the adapter and client application- Specified by:
sendHoldEventin interfaceRFSCoreTrade
-
createPickUpTradeEvent
Create a
TradeEventthat can be passed toto trigger the PickUp transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createPickUpTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of PickUpTradeEvent.
-
sendPickUpEvent
Send a
TradeEventto trigger the PickUp transition in the trade model of the adapter and client application- Specified by:
sendPickUpEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendPickUpEvent
public void sendPickUpEvent()Send a
TradeEventwith no fields to trigger the PickUp transition in the trade model of the adapter and client application- Specified by:
sendPickUpEventin interfaceRFSCoreTrade
-
createTradeConfirmationTradeEvent
Create a
TradeEventthat can be passed toto trigger the TradeConfirmation transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createTradeConfirmationTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of TradeConfirmationTradeEvent.
-
sendTradeConfirmationEvent
Send a
TradeEventto trigger the TradeConfirmation transition in the trade model of the adapter and client application- Specified by:
sendTradeConfirmationEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendTradeConfirmationEvent
Send a
TradeEventto trigger the TradeConfirmation transition in the trade model of the adapter and client application- Parameters:
message- The message to send.
-
createTradeConfirmationTradeEvent
@NotNull public @NotNull TradeConfirmationTradeEvent createTradeConfirmationTradeEvent(@NotNull @NotNull Message message) Create a
TradeEventthat can be passed toto trigger the TradeConfirmation transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createTradeConfirmationTradeEventin interfaceRFSCoreTrade- Parameters:
message- a Message to be passed to the TradeEvent- Returns:
- A new instance of TradeConfirmationTradeEvent.
-
createDetailsUpdateTradeEvent
Create a
TradeEventthat can be passed toto trigger the DetailsUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent- Returns:
- A new instance of DetailsUpdateTradeEvent.
-
sendDetailsUpdateEvent
Send a
TradeEventto trigger the DetailsUpdate transition in the trade model of the adapter and client application- Parameters:
event- The event to send.
-
sendDetailsUpdateEvent
Send a
TradeEventto trigger the DetailsUpdate transition in the trade model of the adapter and client application- Parameters:
message- The message to send.
-
createDetailsUpdateTradeEvent
@NotNull public @NotNull DetailsUpdateTradeEvent createDetailsUpdateTradeEvent(@NotNull @NotNull Message message) Create a
TradeEventthat can be passed toto trigger the DetailsUpdate transition in the trade model of the adapter and client applicationTrade.sendEvent- Parameters:
message- a Message to be passed to the TradeEvent- Returns:
- A new instance of DetailsUpdateTradeEvent.
-
createAcceptWarningAckTradeEvent
Create a
TradeEventthat can be passed toto trigger the AcceptWarningAck transition in the trade model of the adapter and client applicationTrade.sendEvent- Specified by:
createAcceptWarningAckTradeEventin interfaceRFSCoreTrade- Returns:
- A new instance of AcceptWarningAckTradeEvent.
-
sendAcceptWarningAckEvent
Send a
TradeEventto trigger the AcceptWarningAck transition in the trade model of the adapter and client application- Specified by:
sendAcceptWarningAckEventin interfaceRFSCoreTrade- Parameters:
event- The event to send.
-
sendAcceptWarningAckEvent
public void sendAcceptWarningAckEvent()Send a
TradeEventwith no fields to trigger the AcceptWarningAck transition in the trade model of the adapter and client application- Specified by:
sendAcceptWarningAckEventin interfaceRFSCoreTrade
-