的minSdkVersion,机器人:机器人之间的关系,目标和QUOT targetSdkVersion和" [英] Relation between android:minSdkVersion, android:targetSdkVersion and "target"

查看:263
本文介绍了的minSdkVersion,机器人:机器人之间的关系,目标和QUOT targetSdkVersion和"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以,我有点糊涂了,我想我理解的意思安卓的minSdkVersion 安卓targetSdkVersion 目标在项目属性。

So, I'm a little confused, I thought I understood the meaning of android:minSdkVersion, android:targetSdkVersion and target in project properties.

现在,我得到了这些设置为:

Right now I got these set to:

    android:minSdkVersion="7" 
    android:targetSdkVersion="13"

    target=android-15

项目 - >属性 - > Android->项目建设目标

当我试图与Android 2.3.3安装在设备上运行该应用程序的应用程序,我看到对设备名称的红叉,但应用程序运行得很好,它没有少。

When I try to run this application application on a device with Android 2.3.3 installed, I see a red cross against the device name but the application runs fine on it none the less.

我在想什么?如果我对建设15,它是如何运行的Andr​​oid-7?这种混乱陈述后,我AdMob的整合到我的应用程序其中规定它需要的最低水平SDK 13。

What am I missing? If I'm building against 15, how is it running on android-7? This confusion stated after I integrated AdMob into my app which states it require minimum SDK level 13.

推荐答案

要描述一次:

  • 安卓的minSdkVersion帮助谷歌播放应用程序过滤器根据自己设备上的用户。例如,用的minSdkVersion =7,浏览的人与只支持6将不会看到你在谷歌应用程序中播放,因而不会下载它,发现它不工作,并留下一个差评的设备: )

  • android:minSdkVersion helps Google Play filter apps for the user based on their device. For instance, with minSdkVersion="7", someone browsing with a device that only supports 6 won't see your app on Google Play, and thus won't download it, find it doesn't work, and leave a bad review :)

安卓targetSdkVersion是一个信号设备哪些API的版本的应用程序是针对测试。新的行为往往默认可用与平台的新版本,用于定位的至少的该版本的平台的应用程序。例如,您targetSdkVersion设置为11或更高,你的动作条的溢出菜单(适用于蜂窝及以上的设备),而不是的耻辱遗留菜单按钮。

android:targetSdkVersion is a signal to the device about which version of the API your app was tested against. New behaviors are often available by default with new versions of the platform, for applications that target at least that version of the platform. For instance, by setting your targetSdkVersion to 11 or higher, you get an overflow menu in the ActionBar (for Honeycomb and up devices) instead of the "legacy menu button of shame".

project.properties目标是有关你应该编译code对平台哪个版本的信号到本地构建系统。一般来说,最好只设置为您所设置的targetSdkVersion。

project.properties target is a signal to your local build system regarding which version of the platform you should be compiling your code against. Generally it's best to just set this to whatever you have set for the targetSdkVersion.

我在想什么?如果我对建设15,它是如何运行   Android的7?

What am I missing? If I'm building against 15, how is it running on android-7?

Android的保持向后兼容因为这个原因。当您使用中增加了平台​​的15版本的API,显然他们不会有一个设备上运行的较旧的设备。

Android maintains backwards compatibility for just this reason. When you use API's that were added in version 15 of the platform, obviously they won't be there on a device running an an older device.

然而,这是可能的(鼓励)来设计应用程序以这样一种方式,利用加在新的平台功能,但优雅降级,这样你的应用程序继续运行在旧的。这里有一个Android的训练课上只是这个话题,叫支持不同平台版本的。

However, it's possible (and encouraged) to design your application in such a way as to take advantage of features added on new platforms, but "degrade gracefully" such that your application continues to run on older ones. There's an Android Training lesson on just this topic, called Supporting Different Platform Versions.

这篇关于的minSdkVersion,机器人:机器人之间的关系,目标和QUOT targetSdkVersion和"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆