In Android support library docs about android.support.v4.os:
Support android.os classes to assist with development of applications for android API level 4 or later.
"Or later" means API 5,6,7 etc.? But a device running API 22(latest at the moment) will automatically support older devices?
I don't quite understand it - it means, I should use this class to make old API 4 devices use my modern API 22 app? Or should I use it to make new phones support old devices
- When should I use this numerous support.v17, support.v13 packages?
- What is backward compatible?
Can you explain typical situation?
Best How To :
"Or later" means api5,6,7 etc?
It means that this code can be used in devices with a old version of Android (api7= Android 2.1, api=8 Android 2.2.... api14 = Android 4.0)
but a device running api22(latest at the moment) will already automatically support older devices?
A device can run only a version of Android. If it is running api22, it means that it has Android 5.1
I dont' quite understand it - it means, i should use this class to make old api 4 devices use my modern api22 app? or should I use it to make new phones support old devices
It means that you can use this library to backport some features introduced with the last api (for example 21) to old devices running a previous api level.
1.When should i use this numerous support.v17, support.v13 packages? 2. what is backward compatible?
You can use them, when you need them... If you would like to use the Google cards you can use the
v7 cardview library for example.
As described in the official link:
Each Support Library is backward-compatible to a specific Android API level.
For example the
- support v4 : minSdk=4
- v7 appcompat library: minSdk=7
- v7 recyclerview library: minSdk = 7
- v7 CardView library: minSdk = 7
can you explain typical situation?
API21 introduced a new widget, the Toolbar. This widget can be used only in device with API >=21.
appcompat rel.21 (a v7 Support Libraries) you can use the Toolbar (pay attention to the package) to implement your Toolbar in old devices running API>=7.