class IO2GResponseReaderFactory

Parents
IAddRef

Brief

The class creates readers to process the content of the trading server responses.

Details

An O2GResponse object contains a response received from the trading server. To process the content of the response object, you must use an appropriate reader based on the response type. For the list of the response types, refer to the O2GResponseType description. The IO2GResponseReaderFactory class provides methods to create readers for all the response types.

To get an instance of the class, use the IO2GSession.getResponseReaderFactory method. For example,

O2GResponseReaderFactory responseFactory = mSession.getResponseReaderFactory();

Example

Get Account ID, Balance, and Used margin [show]

Public Methods

createAccountsTableReader

Creates a reader to process a response to a request for initial account information.

createClosedTradesTableReader

Creates a reader to process a response to a request for initial closed position information.

createLastOrderUpdateResponseReader

Creates a reader to process a response to the current state of an order request.

createMarketDataSnapshotReader

Creates a reader to process a response to a request for historical pricing information.

createMessagesTableReader

Creates a reader to process a response to a request for initial message information.

createOffersTableReader

Creates a reader to process a response to a request for initial offer information.

createOrderResponseReader

Creates a reader to process a response to a request for an order creation.

createOrdersTableReader

Creates a reader to process a response to a request for initial order information.

createSystemPropertiesReader

Creates a reader to process a response to a request for system properties information.

createTablesUpdatesReader

Creates a reader to process a table update response that is provided by the trading server automatically.

createTradesTableReader

Creates a reader to process a response to a request for initial open position information.

processMarginRequirementsResponse

Checks whether margin requirements information is loaded or not.

back