android 学习十 support package
来源:互联网 发布:mac python配置 编辑:程序博客网 时间:2024/06/17 14:39
support package
支持的最低版本的api版本是4.
support package 包含静态的support 库,通过将这个库添加到android application 中我们便可以使用那些不适用于旧版本的或者是那些提供的实用的但不属于框架的api。目的就是通过捆绑更多的api到application中来简化开发,同时可以使你话费更少的精力在平台的版本问题上。
note:support package 包含不止一个的support library每一个都有一个不同的支持的最低版本的api版本,例如一个库要求api版本是四或者更高,同时另一个库要求api版本是13或者更高(V13是V4的一个超集,包含了额外的支持V13api的类),最低版本通过名字来表示如V4 V13。
在google最新的sdk文档中我们能看到最新版本support package 的修订。
以下摘录自google的官方文档,告诉大家怎么下载support package 以及如何将support library 加入到自己的工程中来,英文很容易懂,就不翻译了。
Downloading the Support Package
The Support Package is provided as a downloadable package from the Android SDK and AVD Manager. To install:
- Launch the SDK and AVD Manager.
From Eclipse, you can select Window > Android SDK and AVD Manager. Or, launch
SDK Manager.exe
from the<sdk>/
directory (on Windows only) orandroid
from the<sdk>/tools/
directory. - Expand the Android Repository, check Android Support package and click Install selected.
- Proceed to install the package.
When done, all files (including source code, samples, and the .jar
files) are saved into the <sdk>/extras/android/support/
directory. This directory contains each of the different support libraries, such as the library for API level 4 and up and the library for API level 13 and up, each named with the respective version (such as v4/
).
Setting Up a Project to Use a Library
To add one of the libraries to your Android project:
- In your Android project, create a directory named
libs
at the root of your project (next tosrc/
,res/
, etc.) - Locate the JAR file for the library you want to use and copy it into the
libs/
directory.For example, the library that supports API level 4 and up is located at
<sdk>/extras/android/support/v4/android-support-v4.jar
. - Add the JAR to your project build path.
In Eclipse, right-click the JAR file in the Package Explorer, select Build Path > Add to Build Path. You should then see the JAR file appear in a new directory called Referenced Libraries.
Your application is now ready to use the library APIs. All the provided APIs are available in the android.support
package (for example, android.support.v4
).
- android 学习十 support package
- android 学习十 support package
- Android support V4 package
- Android Support Library package
- Android Support Package r7 发布
- Android Support Package 支撑包
- support package
- package android.support.v4.view does not exist
- BSP(Board Support Package
- Support Package SAPKH60008 Error
- Android Design Support Library学习
- Android Support Library 学习入门
- Zip package support in C++
- Android学习十 多媒体
- Test run failed: Unable to find instrumentation target package: android.support.v7.appcompat
- Android - Design Support Library 学习总结
- Android - Design Support Library 学习总结 2
- Android Support Library学习(一)
- 结构体struct简介(下)
- 给浮躁的软件业同仁
- main 之前与之后
- JavaScript内置对象(2)
- C语言struct内存占用问题
- android 学习十 support package
- JqueryUI datepicker(日历)插件--实例选择日期
- 实验报告1
- 为什么Hadoop将一定会是分布式计算的未来?
- Android--入门---17---(Android sharedPreference --用户偏好)
- [算法导论读书笔记]Dijkstra算法
- bitmap size exceeds VM budget 的解决办法分享
- mysql -- 修改mysql用户的密码
- 从敏捷实践者的角度看VersionOne的2011年度敏捷状态报告