The DeltaStreamCallParams, TableCallParams, TableStreamCallParams, RequestCallParams auxiliary classes contain basic attributes that are used to exchange requests with mobile platform server.
Basic attributes are stored in the BaseRequestParams class:
Attribute | Data type | Description |
data | String | Data sent in request body. |
headers | Map | Dictionary with additional HTTP headers. |
retryCount | Int |
Number of request repetitions or resource downloading repetitions. |
retryIntervalSec | Int |
Interval between repetitions of resource downloading in seconds. |
filename | String | File name to save data. |
Auxiliary classes interact with basic attributes via specified parameters, for example:
val param = DeltaStreamCallParams()
param.data = <data>
Example of setting up resuming of resource downloading:
final TableStreamCallParams params = new TableStreamCallParams();
params.setDataBasePath("/path/to/database");
params.setRetryCount(10);
params.setRetryIntervalSec(1);
hyperHive.requestAPI.tableStream("resource", params);
The DeltaStreamCallParams class is used to get data delta.
Attribute | Data type | Description |
databasePath | String | Path to database file. NOTE. If the "filename" attribute is set at the same time, data is not loaded to the database. |
withCache | Boolean | Resource is cacheable or not |
The TableCallParams class is used to get data in the JSON format.
Attribute | Data type | Description |
args | Map |
A dictionary with additional arguments that are added to URL. |
The TableStreamCallParams class is used to get data with writing to database on a mobile device.
Attribute | Data type | Description |
transactionID | String | Transaction ID. |
args | Map |
A dictionary with additional arguments that are added to URL. |
See also:
Android Framework | Initializing and Setting Up Android Framework | Describing Android Framework Methods