extractUpdate

fun extractUpdate(appId: String, zipFile: File): File?

Deprecated

No longer supported

Replace with

sync

Synchronous function to extract a downloaded zipped app.

Example usage (kotlin):

val checkScope = CoroutineScope(Dispatchers.IO)
checkScope.launch {
val response = LiveUpdateManager.extractUpdate("appId", zipFile)
println(response?.path)
}

Example usage (Java):

Executor executor = Executors.newSingleThreadExecutor();
executor.execute(() -> {
File extractedFile = LiveUpdateManager.extractUpdate(getContext(), zipFile);
});

Return

a file directory where the app was unzipped

Parameters

appId

the ID of the registered app

zipFile

the zipped app download to extract


fun extractUpdate(appId: String, zipFile: File, callback: ExtractCallback)

Deprecated

No longer supported

Replace with

sync

Asynchronous function to extract a downloaded zipped app.

Example usage (kotlin):

LiveUpdateManager.extractUpdate("appId", zipFile, object : ExtractCallback {
override fun onComplete(result: File?) {
println(response?.path)
}
})

Example usage (Java):

LiveUpdateManager.extractUpdate(getContext(), zipFile, extractedFile -> {
// Do something with file
});

Parameters

appId

the ID of the registered app

zipFile

the zipped app download to extract

callback

an ExtractCallback to handle the response from the extract request