推荐组件:
The SDK repository contains a range of components that you can download. Use the table below to determine which components you need, based on whether you want to set up a basic, recommended, or full development environment:
汉语:SDK库包含了一系列你可以下载的组件。用下表来确定哪些是你需要的组件。基于你是否想要建立一个基本的,推荐 (加上基本)、完整 (加上推荐)发展的环境
环境 | SDK 组件 | 注解 |
---|---|---|
基础 | SDK Tools | If you've just installed the SDK starter package, then you already have the latest version of this component. The SDK Tools component is required to develop an Android application. Make sure you keep this up to date. |
SDK Platform-tools | This includes more tools that are required for application development. These tools are platform-dependent and typically update only when a new SDK platform is made available, in order to support new features in the platform. These tools are always backward compatible with older platforms, but you must be sure that you have the latest version of these tools when you install a new SDK platform. | |
SDK platform | You need to download at least one platform into your environment, so that you will be able to compile your application and set up an Android Virtual Device (AVD) to run it on (in the emulator). To start with, just download the latest version of the platform. Later, if you plan to publish your application, you will want to download other platforms as well, so that you can test your application on the full range of Android platform versions that your application supports. | |
推荐 (加上基本) | Documentation | The Documentation component is useful because it lets you work offline and also look up API reference information from inside Eclipse. |
Samples | The Samples components give you source code that you can use to learn about Android, load as a project and run, or reuse in your own app. Note that multiple samples components are available — one for each Android platform version. When you are choosing a samples component to download, select the one whose API Level matches the API Level of the Android platform that you plan to use. | |
完整 (加上推荐) | Google APIs | The Google APIs add-on gives your application access to the Maps external library, which makes it easy to display and manipulate Maps data in your application. |
Additional SDK Platforms | If you plan to publish your application, you will want to download additional platforms corresponding to the Android platform versions on which you want the application to run. The recommended approach is to compile your application against the lowest version you want to support, but test it against higher versions that you intend the application to run on. You can test your applications on different platforms by running in an Android Virtual Device (AVD) on the Android emulator. |
Once you've installed at least the basic configuration of SDK components, you're ready to start developing Android apps. The next section describes the contents of the Android SDK to familiarize you with the components you've just installed.
For more information about using the Android SDK and AVD Manager, see the Adding SDK Components document.
探索SDK(可选择的)
Once you've installed the SDK and downloaded the platforms, documentation, and add-ons that you need, we suggest that you open the SDK directory and take a look at what's inside.
The table below describes the full SDK directory contents, with components installed.
名字 | 描述 | ||
---|---|---|---|
add-ons/ | Contains add-ons to the Android SDK development environment, which let you develop against external libraries that are available on some devices. | ||
docs/ | A full set of documentation in HTML format, including the Developer's Guide, API Reference, and other information. To read the documentation, load the file offline.html in a web browser. | ||
platform-tools/ | Contains platform-dependent development tools that may be updated with each platform release. The platform tools include the Android Debug Bridge (adb ) as well as other tools that you don't typically use directly. These tools are separate from the development tools in the tools/ directory because these tools may be updated in order to support new features in the latest Android platform. | ||
platforms/ | Contains a set of Android platform versions that you can develop applications against, each in a separate directory. | ||
<platform>/ | Platform version directory, for example "android-11". All platform version directories contain a similar set of files and subdirectory structure. Each platform directory also includes the Android library (android.jar ) that is used to compile applications against the platform version. | ||
samples/ | Sample code and apps that are specific to platform version. | ||
tools/ | Contains the set of development and profiling tools that are platform-independent, such as the emulator, the Android SDK and AVD Manager, ddms , hierarchyviewer and more. The tools in this directory may be updated at any time using the Android SDK and AVD Manager and are independent of platform releases. | ||
SDK Readme.txt | A file that explains how to perform the initial setup of your SDK, including how to launch the Android SDK and AVD Manager tool on all platforms. | ||
SDK Manager.exe | Windows SDK only. A shortcut that launches the Android SDK and AVD Manager tool, which you use to add components to your SDK. |
Optionally, you might want to add the location of the SDK's tools/
and platform-tools
to your PATH
environment variable, to provide easy access to the tools.
单词注解:respository[ri'pɔzitəri]:n. 贮藏室,仓库;知识库;智囊团