Targeting Specific SDK Versions


Build your own Android App Dev Empire

Get Instant Access

Android devices run different versions of the Android platform. Often, you see old, less powerful, or even less expensive devices running older versions of the Android platform, whereas newer, more powerful devices that show up on the market often run the latest Android software.

There are now dozens of different Android devices in users' hands. Developers must decide who their target audience is for a given application. Are they trying to support the largest population of users and therefore want to support as many different versions of the platform as possible? Or are they developing a bleeding-edge game that requires the latest device hardware?

Developers can specify which versions of the Android platform an application supports within its Android manifest file using the <uses-sdk> tag.This tag has three important attributes:

■ The minSdkVersion attribute:This attribute specifies the lowest API level that the application supports.

■ The targetSdkVersion attribute:This attribute specifies the optimum API level that the application supports.

■ The maxSdkVersion attribute:This attribute specifies the highest API level that the application supports.

The Android Market filters applications available to a given user based upon settings such as the <uses-sdk> tag within an application's manifest file. This is a required tag for applications that want to be published on the Android Market. Neglecting to use this tag results in a warning in the build environment.

Each attribute of the <uses-sdk> tag is an integer that represents the API level associated with a given Android SDK. This value does not directly correspond to the SDK version. Instead, it is the revision of the API level associated with that SDK. The API level is set by the developers of the Android SDK.You need to check the SDK documentation to determine the API level value for each version.


With each new Android SDK version, this API level is incremented. This information is always provided with the SDK release documentation.

Table 5.1 shows the Android SDK versions available for shipping applications. Table 5.1 Android SDK Versions and Their API Levels

Android SDK Version API Level (Value as Integer)

Android 1.0 SDK 1

Android 1.1 SDK 2

Android 1.5 SDK (Cupcake) 3

Android 1.6 SDK (Donut) 4

Table 5.1 Continued Android SDK Version

Android 2.2 SDK (FroYo) Android SDK (Gingerbread)

API Level (Value as Integer)

Was this article helpful?

0 0
Easy Software Profits

Easy Software Profits

Here's How Anyone Can Start, Build and Run their Own Successful Software Empire Without Knowing the First Thing About Programming, Scripting Or Any 'Coder' Stuff. There is no doubt about it software sells. Software has a high percieved value and it solves problems for people.  A claim that can't always be made for PDF books, Video products and the like.

Get My Free Ebook

Post a comment