The Offline OData plugin provides offline OData support to Kapsel applications. OData version 2.0 (OData V2) is supported. The plugin is supported for use with applications on the Android and iOS platforms.
The plugin provides the client with the ability to define offline stores for an OData producer. When an offline store is first opened, it synchronizes with the OData producer. OData requests made against this plugin use the available open offline stores.
The plugin uses the OData component from the SAP Mobile Platform SDK.
An OData request may be made directly with an XMLHttpRequest, or a library other than datajs may be used. For these cases, you must use the sap.OData.request method to perform the request. This method is used by the custom httpclient, which can be used as a reference.
You must explicitly refresh your stores to get changes from the OData producer. The plugin provides a refresh method that you can call to refresh the whole store or a subset of it.
The event onrequesterror is fired if a request fails against the OData producer.
You can provide detailed information about errors through the ErrorArchive. The ErrorArchive logs business logic errors and ETag mismatch errors. You can configure an offline application to access the ErrorArchive so that end users can read and delete logged errors. See Designing an Offline Application to Handle Conflicts and Errors in Developer < Native OData Application Development.