com.apama.oms
Event ExchangeEngine


The main component that constructs a matching engine and accepts orders to submit/amend/cancel or alternatively is set up to listen to NewOrder/Amend/Cancel events.
Since:
CMF 1.1.2
Version:
9.12
Listens:
com.apama.oms.AmendOrder - 
com.apama.oms.CancelAllUserOrders - 
com.apama.oms.CancelOrder - 
com.apama.oms.CancelOrderGroup - 
com.apama.oms.ClearOrderbook - 
com.apama.oms.NewOrder - 
com.apama.oms.OrderReceiveFinished - 

Constant Summary
 constant stringORDER_GROUP_EXTRA_PARAM := "OrderGroup"

Order group.
 
Member Summary
 com.apama.oms.CreateExchangeEnginecreate

The creation object contains the relevant market-data keys and parameters set by the for setting up the simulation platform. The omsInputKey is for the inference section and the exchangeEngine listens on the omsOutputKey.
 dictionary<com.apama.oms.GroupKey, dictionary<string, boolean > >orderGroups

A set of order groups, used for cancel-by-group. This allows construction of order groups, be they groups on the same symbol (e.g. VWAP orders) or groups across different symbols (e.g. basket orders).
 dictionary<string, dictionary<string, string > >ordersByUser

A record of orders submitted by each user, to support per-user operations (e.g. cancel all user's orders).
 com.apama.oms.ConstantsOMSConsts

Helper object containing various string constants.
 com.apama.oms.OrderPrioritiespriorities

A helper object to store priority data by ID. This allocates priorities in ascending order, such that they can always be used as a sorting mechanism for order execution.
 com.apama.oms.ExchangeEngineExtensionInterfaceexchangeExtensions

Exchange extensions.
 com.apama.oms.MatchResultConstantsmrc

 
Action Summary
 voidhandleUserOrderCompletion(string ownerId, string serviceId, string orderId)

This listens for orders being finished, removes them from the list for that user, and reports that the group is no longer active if/when all orders are completed.
 voidinitCreate(com.apama.oms.CreateExchangeEngine create, com.apama.oms.ExchangeEngineExtensionInterface exchangeExtensions, string instanceId, context mainCtx, action<com.apama.oms.OrderState > updateCallBack)

Constructor used to create an exchange engine.
 voidondie()

Used to end engine's functions by cleaning the book and stopping listeners.
 
Constant Detail

ORDER_GROUP_EXTRA_PARAM

constant string ORDER_GROUP_EXTRA_PARAM := "OrderGroup"
Order group.
Member Detail

create

com.apama.oms.CreateExchangeEngine create
The creation object contains the relevant market-data keys and parameters set by the for setting up the simulation platform. The omsInputKey is for the inference section and the exchangeEngine listens on the omsOutputKey.

exchangeExtensions

com.apama.oms.ExchangeEngineExtensionInterface exchangeExtensions
Exchange extensions.

mrc

com.apama.oms.MatchResultConstants mrc

OMSConsts

com.apama.oms.Constants OMSConsts
Helper object containing various string constants.

orderGroups

dictionary<com.apama.oms.GroupKey, dictionary<string, boolean > > orderGroups
A set of order groups, used for cancel-by-group. This allows construction of order groups, be they groups on the same symbol (e.g. VWAP orders) or groups across different symbols (e.g. basket orders).

ordersByUser

dictionary<string, dictionary<string, string > > ordersByUser
A record of orders submitted by each user, to support per-user operations (e.g. cancel all user's orders).

priorities

com.apama.oms.OrderPriorities priorities
A helper object to store priority data by ID. This allocates priorities in ascending order, such that they can always be used as a sorting mechanism for order execution.
Action Detail

handleUserOrderCompletion

void handleUserOrderCompletion(string ownerId, string serviceId, string orderId)
This listens for orders being finished, removes them from the list for that user, and reports that the group is no longer active if/when all orders are completed.
Parameters:
ownerId
serviceId
orderId
Listens:
com.apama.oms.OrderReceiveFinished - 

initCreate

void initCreate(com.apama.oms.CreateExchangeEngine create, com.apama.oms.ExchangeEngineExtensionInterface exchangeExtensions, string instanceId, context mainCtx, action<com.apama.oms.OrderState > updateCallBack)
Constructor used to create an exchange engine.
Parameters:
create - Whether to create a dataview or not
exchangeExtensions
instanceId - A unique identifier for the exchange engine
mainCtx - The main context
updateCallBack - Callback to be called on each update
Listens:
com.apama.oms.ClearOrderbook - 

ondie

void ondie()
Used to end engine's functions by cleaning the book and stopping listeners.