check For Update
Deprecated
No longer supported
Replace with
sync
Content copied to clipboard
Synchronous function to check for an update for an app.
Example usage (kotlin):
val checkScope = CoroutineScope(Dispatchers.IO)
checkScope.launch {
val response = LiveUpdateManager.checkForUpdate(context, "appId")
println(response.body.toString())
}
Content copied to clipboard
Example usage (Java):
Executor executor = Executors.newSingleThreadExecutor();
executor.execute(() -> {
CheckResponse response = LiveUpdateManager.checkForUpdate(getContext(), "appId");
// Do something with response
});
Content copied to clipboard
Return
the CheckResponse result
Parameters
context
an Android Context used during the update check
app Id
the ID of the registered app to check
Deprecated
No longer supported
Replace with
sync
Content copied to clipboard
Asynchronous function to check for an update for an app.
Example usage (kotlin):
LiveUpdateManager.checkForUpdate(context, "appId", object : CheckCallback {
override fun onComplete(result: CheckResponse?) {
// Do something with the result
}
})
Content copied to clipboard
Example usage (Java):
LiveUpdateManager.checkForUpdate(context, "appId", checkResponse -> {
// Do something with response
});
Content copied to clipboard
Parameters
context
an Android Context used during the update check
app Id
the ID of the registered app to check
callback
a CheckCallback to handle the response from the update check request