Package | Description |
---|---|
com.salesforce.androidsdk.rest |
Modifier and Type | Method and Description |
---|---|
RestResponse |
RestClient.sendSync(RestRequest restRequest)
Send the given restRequest synchronously and return a RestResponse
Note: Cannot be used by code on the UI thread (use sendAsync instead).
|
RestResponse |
RestClient.sendSync(RestRequest restRequest,
Interceptor... interceptors)
Send the given restRequest synchronously and return a RestResponse
Note: Cannot be used by code on the UI thread (use sendAsync instead).
|
Modifier and Type | Method and Description |
---|---|
void |
RestClient.AsyncRequestCallback.onSuccess(RestRequest request,
RestResponse response)
NB: onSuccess runs on a network thread
If you are making your call from an activity and need to make UI changes
make sure to first consume the response and then call runOnUiThread
result.consumeQuietly(); // consume before going back to main thread
runOnUiThread(new Runnable() {
|