What is AndroidX?

后端 未结 10 1274
死守一世寂寞
死守一世寂寞 2020-11-22 03:38

I am reading about a room library of Android. I see they changed package android to androidx. I did not understand that. Can someone explain, pleas

10条回答
  •  萌比男神i
    2020-11-22 04:36

    Based on the documentation:

    androidx is new package structure to make it clearer which packages are bundled with the Android operating system, and which are packaged with your app's APK. Going forward, the android.* package hierarchy will be reserved for Android packages that ship with the operating system; other packages will be issued in the new androidx.* package hierarchy.

    The re-designed package structure is to encourage smaller and more focused libraries. You find details regarding the artifact mappings here.

    There are support libraries (containing component and packages for backward compatibility) named "v7" when the minimal SDK level supported is 14, the new naming makes it clear to understand the division between APIs bundled with platform and the libraries for app developers which are used on different versions of Android. You can refer to official announcement for more details.

提交回复
热议问题