public method O2GLastOrderUpdateResponseReader.getOrder
Brief
Gets an instance of the class that provides access to order information.
| Declaration | ||||
|
||||
Details
The returned value of the method provides access to the current order state through the O2GOrderRow.getStatus method.
For example,
String status = orderRow.getStatus();
Example
Getting the current order status [hide]
// Implementation of IO2GResponseListener interface public method onRequestCompleted
public void onRequestCompleted(String requestID, O2GResponse response) {
O2GResponseReaderFactory readerFactory = mSession.getResponseReaderFactory();
if (readerFactory != null) {
if (response.getType() == O2GResponseType.GET_LAST_ORDER_UPDATE) {
O2GLastOrderUpdateResponseReader lastOrderUpdateResponseReader = readerFactory.createLastOrderUpdateResponseReader(response);
O2GOrderRow orderRow = lastOrderUpdateResponseReader.getOrder();
System.out.println("OrderID: " + orderRow.getOrderID() +
" Status: " + orderRow.getStatus());
}
}
}
Declared in O2GLastOrderUpdateResponseReader