Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

what is a non-SDK interface

After searching new Android P features, I came across the non-SDK interfaces restriction. and my question is,

What is a non-SDK interface or an SDK interface? What is the difference between them? specially that makes non-SDK once better. Examples of popular SDK and non-SDK interfaces available for android.

P.S. I came across abstract answers differentiating between SDK and API interfaces but it didn't fulfill my questions :/

like image 720
aya salama Avatar asked Apr 30 '18 12:04

aya salama


People also ask

What is non SDK interface?

Non-SDK interfaces that are currently unrestricted and your app can use. Note however, that these interfaces are unsupported and subject to change without notice. Expect these interfaces to be conditionally blocked in future Android versions in a max-target-x list. SDK ( whitelist )

Do I need SDK for Android studio?

You must install Oracle JDK before installing Android Studio, so please don't start this step until you have completed Step 1 above. Download Android Studio from the following address: Android Studio Download Page.

What is SDK APK?

The Android SDK is a software development kit that includes a comprehensive set of development tools. These include a debugger, libraries, a handset emulator based on QEMU, documentation, sample code, and tutorials.

What is Android hidden API?

Android Hidden APIs are classes, methods and resources that Google hides from you because of stability reason. These features are hidden because they may be changed on next API version. The internal APIs are located in package com.


1 Answers

Quoting the documentation:

Generally speaking, SDK interfaces are those ones found documented in the Android framework Package Index.

Not everything in the framework appears in the documentation. Classes, methods, fields, and such marked with @hide in the source code are available at runtime but are not part of the SDK and do not appear in the documentation. These items can only be accessed by unconventional means, such as reflection.

That is what Android P is starting to ban.

For years, I have been advising developers not to access such things, because they are unreliable. Any Android device may not have the hidden stuff, due to changes based on the Android version or device manufacturer/ROM modder tweaks. Now, Google is going to enforce this advice more firmly, at least in some cases.

specially that makes non-SDK once better

They are not "better". However, they may offer access to certain features that are not available in the SDK, for one reason or another (e.g., API is not settled yet).

like image 66
CommonsWare Avatar answered Sep 20 '22 23:09

CommonsWare