Apama Capital Markets Foundation Documentation : Capital Markets Foundation : Order Management : Risk Firewall : Receiving approved orders from a risk firewall : Setting accepted-amended-order callbacks
Setting accepted-amended-order callbacks
After a risk firewall approves an amendment to an order, it calls any accepted-amended-order callbacks that you have added to the order receiver that receives the approved order amendment. For example, you might want to add an accepted-amended-order callback that forwards approved order amendments to a particular adapter.
To add an accepted-amended-order callback, call com.apama.firewall.OrderReceiver.addAcceptedAmendCallback(). This action takes one argument, which is the callback to be executed. The callback itself takes one argument, which is a com.apama.oms.AmendOrder object. The action registers a callback with the risk firewall instance it is executed on. The registered callback is executed whenever the risk firewall approves an amended order. You can add more than one accepted-amended-order callback.
The addAcceptedAmendCallback() action returns a unique integer reference Id that you can use to remove the callback at a later date if required.
To remove a previously-added accepted-amended-order callback, call OrderReceiver.removeAcceptedAmendCallback() and specify the integer reference Id that was returned when you added the callback. To remove all previously-added accepted-amended-order callbacks, call the OrderReceiver.clearAcceptedAmendCallbacks() action.
Copyright © 2013-2016 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback