class O2GMessagesTableResponseReader
Parents | |
|
Brief
The class reads a stream of message rows coming from the trading server.
Details
All data from the trading server come in the form of responses. The type of the response depends on the type of the request.
An O2GResponse
object of the type GET_MESSAGES
comes from the trading server as a response to the request for initial message information.
The response consists of the Messages table rows. Every row is represented by an O2GMessageRow
object.
In order to read this response you must use the O2GMessagesTableResponseReader
.
Getting the response
If your application uses the O2GTableManager
, the Messages table is
always loaded during the login process.
This information is kept in the O2GMessagesTable
object.
If your application does not use the O2GTableManager
, the initial message information needs to be requested.
The Messages table always loaded by the server automatically during the login process.
To obtain the GET_MESSAGES
response, call the
O2GLoginRules
.getTableRefreshResponse
method.
For example,
O2GResponse messagesResponse = loginRules.getTableRefreshResponse(O2GTableType.MESSAGES);
Instantiating the class
After receiving the GET_MESSAGES
response, an instance of the
O2GMessagesTableResponseReader
class can be obtained by calling the
O2GResponseReaderFactory
.createMessagesTableReader
method.
For example:
O2GResponseReaderFactory responseFactory = session.getResponseReaderFactory();
O2GMessagesTableResponseReader messagesReader = responseFactory.createMessagesTableReader(messagesResponse);
Example
Get Messages information [show]
The namespace is com.fxcore2
.
Public Methods | |
Gets the value of a cell. |
|
Gets an instance of the class that provides access to the list of table columns. |
|
Gets a row by its index. |
|
Gets a row from the Messages table. |
|
Gets the type of a trading table. |
|
Checks whether the cell value can be used or not. |
|
Gets the number of rows in the reader. |