I found an example of using OTA updates. But i need to use android.os.UpdateEngine
This is SystemApi, and i found this question on StackOverFlow, where answer is wrote to android.mk file LOCAL_SDK_VERSION := system_current
I never worked with android.mk files before, so i created it and put to app/android.mk
This is all that i have in mine android.mk file:
LOCAL_PATH := $(call my-dir)
LOCAL_SDK_VERSION := system_current
Also i add this to build.gradle file (i dont use NDK in my app, but i dont know another ways to use android.mk file)
sourceSets.main {
jniLibs.srcDir 'src/main/libs' //set libs as .so's location instead of jniLibs
jni.srcDirs = [] //disable automatic ndk-build call with auto-generated Android.mk
}
externalNativeBuild {
ndkBuild {
path 'Android.mk'
}
}
But anyway, when i writing import android.os.UpdateEngine i'm getting Cannot resolve symbol "UpdateEngine"
I was trying to search on Stack, Google, but cannot find solution.