You can use X_TRADER®to monitor market price information and submit orders.
To monitor market price information:
Connect to Trading Technologies®X_TRADER usingxtrdr
.
创建一个事件通知使用createNotifier
.
Create an instrument and attach it to the notifier usingcreateInstrument
. Optionally, usegetData
to return information on the instrument that you have created.
Close the Trading Technologies X_TRADER connection usingclose
.
To submit orders to X_TRADER:
Connect to Trading Technologies X_TRADER usingxtrdr
.
创建一个事件通知使用createNotifier
.
Create an instrument and attach it to the notifier usingcreateInstrument
. Optionally, usegetData
to return information on the instrument that you have created.
Create an order set usingcreateOrderSet
to define the level of the order status events and event handlers for orders that will be submitted to X_TRADER.
Define the order usingcreateOrderProfile
. An order profile contains the settings that define an individual order to be submitted.
Route the order for execution using theOrderSet
object created bycreateOrderSet
in step 4.
Close the Trading Technologies X_TRADER connection usingclose
.
To monitor market price information and respond to market changes by automatically submitting orders to X_TRADER:
Connect to Trading Technologies X_TRADER usingxtrdr
.
创建一个事件通知使用createNotifier
.
Create an instrument and attach it to the notifier usingcreateInstrument
. UsegetData
to return information on the instrument that you have created.
Define events by assigning callbacks for validating or invalidating an instrument and performing calculations based on the event. Based on some predefined condition reached when changes in the incoming data satisfy the condition, event callbacks execute the functions in steps 5, 6, and 7.
Create an order set usingcreateOrderSet
to define the level of the order status events and event handlers for orders that will be submitted to X_TRADER.
Define the order usingcreateOrderProfile
. An order profile contains the settings that define an individual order to be submitted.
Route the order for execution using theOrderSet
object created bycreateOrderSet
in step 5.
Close the Trading Technologies X_TRADER connection usingclose
.