英文翻译资料原文及译文android方面[1]
- 格式:doc
- 大小:147.50 KB
- 文档页数:20
1 什么是Android1.1 主要技巧和思想●历史的嵌入式器件编程●开放手机联盟的解释●第一眼看到Android的主屏幕可以这么说,暂时,传统的桌面应用程序开发者已经被惯坏了。
这个不是说桌面应用程序开发比其他形式的开发很简单。
总之,作为传统桌面的应用程序开发者,凡是我们能想象到的各种应用程序,我们就一定有能力创造。
包括我自己,因为我也是从做桌面程序开始的。
一方面已经使得桌面程序更容易理解就是我们已经有能力去跟桌面操作系统相互作用,因此,任何底部的硬件很自由的相互作用。
这种类型独立自主的程序编制,然而,对于很小的开发者团体来说是不敢冒险的去搞手机发展这样浑浊的技术的。
注解:我提到两种不同的开发商在此讨论:传统的桌面应用程序开发,他们能在任何语言环境下工作,而且最终的产品和程序是用来运行“桌面”操作系统的;还有Android 程序开发者,那些开发Android平台开发工具的JAVA程序开发人员。
这不是说跟其他人比起来谁好谁坏。
其实,区别目的仅仅在于想说明并比较Android桌面操作系统环境的开发风格,工具。
1.2 嵌入式器件编程的简要历史有很长一段时间,手机的开发者由大的著名嵌入式的开发团队中的少数人组成,作为嵌入式设备的开发者。
相对于桌面开发或者后续的网络开发,被视作更少“魅力”,而且嵌入式设备的开发通常因为硬件和操作系统而处于劣势。
因为嵌入式设备的制造商们太小气,他们要保护他们硬件方面的秘密,所以他们给开发者们非常有限的库去运行当他们尝试去让一些特定的设备去相互作用。
嵌入设备与桌面系统显著不同的一部分是嵌入设备是个有特色的“芯片上的电脑”。
例如:考虑你的标准电话遥控。
这个并不是一个非常强大并且复杂性的技术。
当任何的按钮被按下去,一个芯片解释一个信号以一种方式已经被编程进了这个设备。
这个允许设备知道什么是从输入设备(键盘)来的需要。
并且如何的响应这些命令(比如,打开电视机)。
这个是一个简单的嵌入式设备的编程。
附录1:外文原文What Is Android?It can be said that, for a while, traditional desktop application developers have beenspoiled. This is not to say that traditional desktop application development is easier thanother forms of development. However, as traditional desktop application developers, wehave had the ability to create almost any kind of application we can imagine. I amincluding myself in this grouping because I got my start in desktop programming.One aspect that has made desktop programming more accessible is that we havehad the ability to interact with the desktop operating system, and thus interact with anyunderlying hardware, pretty freely (or at least with minimal exceptions). This kind offreedom to program independently, however, has never really been available to thesmall group of programmers who dared to venture into the murky waters of cell phonedevelopment.For a long time, cell phone developers comprised a small sect of a slightly larger group of developers known as embedded device developers. Seen as a less “glamorous” sibling to desktop—and later web—development, embedded device development typically got the proverbial short end of the stick as far as hardware and operating system features, because embedded device manufacturers were notoriously stingy on feature support. Embedded device manufacturers typically needed to guard their hardware secrets closely, so they gave embedded device developers few libraries to call when trying to interact with a specific device. Embedded devices differ from desktops in that an embedded device is typically a “computer on a chip.” For example, consider your standard television remote control; it is not really seen as an overwhelming achievement of technological complexity. When any button is pressed, a chip interprets the signal in a way that has been programmed into the device. This allows the device to know what to expect from the input device (key pad), and how to respond to those commands (for example, turn on the television). This is a simple form of embedded device programming. However, believe it or not, simple devices such as these are definitely related to the roots of early cell phone devices and development.Most embedded devices ran (and in some cases still run) proprietary operating systems. The reason for choosing to create a proprietary operating system rather than use any consumer system was really a product of necessity. Simple devices did not need very robust and optimized operating systems.As a product of device evolution, many of the more complex embedded devices, such as early PDAs, household security systems, and GPSs, moved to somewhat standardized operating system platforms about five years ago. Small-footprintoperating systems such as Linux, or even an embedded version of Microsoft Windows, have become more prevalent on many embedded devices. Around this time in device evolution, cell phones branched from other embedded devices onto their own path. This branching is evident when you examine their architecture.Nearly since their inception, cell phones have been fringe devices insofar as they run on proprietary software—software that is owned and controlled by the manufacturer, and is almost always considered to be a “closed” system. The practice of manufacturers using proprietary operating systems began more out of necessity than any other reason. That is, cell phone manufacturers typically used hardware that was completely developed in-house, or at least hardware that was specifically developed for the purposes of running cell phone equipment. As a result, there were no openly available, off-the-shelf software packages or solutions that would reliably interact with their hardware. Since the manufacturers also wanted to guard very closely their hardware trade secrets, some of which could be revealed by allowing access to the software level of the device, the common practice was, and in most cases still is, to use completely proprietary and closed software to run their devices. The downside to this is that anyone who wanted to develop applications for cell phones needed to have intimate knowledge of the proprietary environment within which it was to run. The solution was to purchase expensive development tools directly from the manufacturer. This isolated many of the “homebrew” develo pers.Another, more compelling “necessity” that kept cell phone development out of the hands of the everyday developer was the hardware manufacturers’ solution to the “memory versus need” dilemma. Until recently, cell phones did little more than execute and receive phone calls, track your contacts, and possibly send and receive short text messages; not really the “Swiss army knives” of technology they are today. Even as late as 2002, cell phones with cameras were not commonly found in the hands of consumers.By 1997, small applications such as calculators and games (Tetris, for example) crept their way onto cell phones, but the overwhelming function was still that of a phone dialer itself. Cell phones had not yet become the multiuse, multifunction personal tools they are today. No one yet saw the need for Internet browsing, MP3 playing, or any of the multitudes of functions we are accustomed to using today. It is possible that the cell phone manufacturers of 1997 did not fully perceive the need consumers would have for an all-in-one device. However, even if the need was present, a lack of device memory and storage capacity was an even bigger obstacle to overcome. More people may have wanted their devices to be all-in-one tools, but manufacturers still had to climb the memory hurdle.To put the problem simply, it takes memory to store and run applications on any device, cell phones included. Cell phones, as a device, until recently did not have the amount of memory available to them that would facilitate the inc lusion of “extra” programs. Within the last two years, the price of memory has reached very low levels.Device manufacturers now have the ability to include more memory at lower prices. Many cell phones now have more standard memory than the average PC had in the mid-1990s. So, now that we have the need, and the memory, we can all jump inand develop cool applications for cell phones around the world, right? Not exactly.Device manufacturers still closely guard the operating systems that run on their devices. While a few have opened up to the point where they will allow some Java-based applications to run within a small environment on the phone, many do not allow this. Even the systems that do allow some Java apps to run do not allow the kind of access to t he “core” system that standard desktop developers are accustomed to having.This barrier to application development began to crumble in November of 2007 whenGoogle, under the Open Handset Alliance, released Android. The Open Handset Allianceis a group of hardware and software developers, including Google, NTT DoCoMo,Sprint Nextel, and HTC, whose goal is to create a more open cell phone environment.The first product to be released under the alliance is the mobile device operatingsystem, Android. (For more information about the Open Handset Alliance, see)With the release of Android, Google made available a host of development toolsand tutorials to aid would-be developers onto the new system. Help files, the platformsoftware development kit (SDK), and even a developers’ community can be found atGoogle’s Android website, /android. This site should be yourstarting point, and I highly encourage you to visit the site.While cell phones running Linux, Windows, and even PalmOS are easy to find, as ofthis writing, no hardware platforms have been announced for Android to run on. HTC, LGElectronics, Motorola, and Samsung are members of the Open Handset Alliance, underwhich Android has been released, so we can only hope that they have plans for a fewAndroid-based devices in the near future. With its release in November 2007, the systemitself is still in a software-only beta. This is good news for developers because it gives usa rare advance look at a future system and a chance to begin developing applications thatwill run as soon as the hardware is released.Android, as a system, is a Java-based operating system that runs on the Linux 2.6 kernel.The system is very lightweight and full featured. Figure 1-1 shows the unmodifiedAndroid home screen.Figure 1-1 The current Android home screen as seen on the Android EmulatorAndroid applications are developed using Java and can be ported rather easily to thenew platform. If you have not yet downloaded Java or are unsure about which version youneed, I detail the installation of the development environment in Chapter 2. Other featuresof Android include an accelerated 3-D graphics engine (based on hardware support),database support powered by SQLite, and an integrated web browser.If you are familiar with Java programming or are an OOP developer of any sort, youare likely used to programmatic user interface (UI) development—that is, UI placementwhich is handled directly within the program code. Android, while recognizing and allowingfor programmatic UI development, also supports the newer, XML-based UI layout. XMLUI layout is a fairly new concept to the average desktop developer. I will cover boththe XML UI layout and the programmatic UI development in the supporting chaptersof this book.One of the more exciting and compelling features of Android is that, because of itsarchitecture, third-party applications—including those that are “home grown”—areexecuted with the same system priority as those that are bundled with the core system.This is a major departure from most systems, which give embedded system apps agreater execution priority than the thread priority available to apps created by third-partydevelopers. Also, each application is executed within its own thread using a verylightweight virtual machine.Aside from the very generous SDK and the well-formed libraries that are availabletous to develop with, the most exciting feature for Android developers is that we now haveaccess to anything the operating system has access to. In other words, if you want tocreate an application that dials the phone, you have access to the phone’s dialer; if youwant to create an application that utilizes the phone’s internal GPS (if equipped), you haveaccess to it. The potential for developers to create dynamic and intriguing applications isnow wide open.On top of all the features that are available from the Android side of the equation,Google has thrown in some very tantalizing features of its own. Developers of Androidapplications will be able to tie their applications into existing Google offerings such asGoogle Maps and the omnipresent Google Search. Suppose you want to write anapplication that pulls up a Google map of where an incoming call is emanating from,or you want to be able to store common search results with your contacts; the doors ofpossibility have been flung wide open with Android.Ask the ExpertQ: What is the difference between Google and the Open Handset Alliance?A: Google is a member of the Open Handset Alliance. Google, after purchasing the originaldeveloper of Android, released the operating system under the Open Handset Alliance.Q: Is Android capable of running any Linux software?A: Not necessarily. While I am sure that there will be ways to get around most any opensource system, applications need to be compiled using the Android SDK to run onAndroid. The main reason for this is that Android applications execute files in a specificformat; this will be discussed in later chapters.Reference:[1]Hello Android. Introdu cing Google’s Mobile Developmeng Platform 3rd.Edition,EdBurnette,The Pragmatic Bookshelf[2]The.Android.Developers.Cookbook Building Applications with the Android SDK,James Steele Nelson,Addison-Wesley[3] Pro Android Media. Developing Graphics,Music,Video and Rich Media Apps for Smartphones and Tablets,Shawn Van Every,Apress[4] Professional.Android.2.Application.Development.(Wrox,.2010,.0470565527)附录2:外文译文什么是Android?可以说,于此同时,传统的桌面应用程序开发人员已经被宠坏了。
Android应用基础毕设论文外文翻译Android ns are developed using the Java programming language。
The Android SDK tools are used to compile the code。
data。
and resource files into an Android package。
which is an archive file with an。
apk n。
A single。
apk file contains all the code for an n and is used by Android-powered devices to install the n.After n。
each Android n XXX。
The Android operating system is a multi-user Linux system。
and each n is treated as a separate user。
By default。
the system assigns a unique Linux user ID to each n。
which is only known to the system and not to the n。
The system sets ns for all files in an n。
so that only the user ID assigned to that n can access them.Furthermore。
each process has its own virtual machine (VM)。
which means that an n's code XXX that an n's code cannot interfere with the code of other ns.By default。
北方民族大学外文文献翻译译文题目对于Android系统的介绍原稿题目An Introduction to Android System系(部)名称: 计算机科学与工程学院学生姓名:王紫晴专业: 信息管理与信息系统学号: 20122395指导教师姓名:张海霞北方民族大学教务处制目录An Introduction to AndroidSystem (1)1.Android system architecture (1)2. Android released version (2)3. Androidapplication features (2)4. Android development environment (3)5. AndroidProgram structure (3)6. Logcat tools (4)7. Hello World (5)对于安卓系统的介绍 (6)1.Android系统架构 (6)2. Andorid已发布的版本 (7)3. Android应用特色 (8)4. Android开发环境 (9)5. Android程序结构 (9)6. Logcat工具 (11)7. Hello World (11)An Introduction to AndroidSystemAbstractIn many organizations, database development is from the beginning of enterprise data modeling, enterprise data modeling to determine the scope of the organization and the general content of the database. This step usually occurs in an organization's information system planning process, it is intended to create an overall description or interpretation of the organization data, rather than the design of a specific database. A particular database provides data for one or more information systems, and the enterprise data model (which may contain many databases) describes the range of data maintained by the organization. In enterprise data modeling, you review the current system, analyze the need to support the nature of the business domain, describe the need for further abstraction of the data, and the planning of one or more database development projects.1.Android system architectureAndroid's system architecture uses a layered architecture of the idea, as shown in figure. From the top to the bottom layer of a total of four, respectively, the application program layer, application framework layer, the system library and the Android runtime and Linux kernel. Each layer function is briefly described as follows:1) application layerThe layer provides a number of core application packages, such as contact management, calendar, SMS, browser, maps and e-mail, etc.. At the same time, people can use the Java language to design and write their own applications, and these procedures and those of the core applications are equal and friendly coexistence.2) application framework layerThis layer is the foundation of Android application development, the developer is in the majority of the situation is in dealing with it. Application framework layer including the window manager, inform manager, content providers, system view, the location manager, phone manager, resource manager, manager, activity manager and XMPP service of ten parts. On the Android platform, developers can fully access the API framework used by the core application. Also, any application can publish its own function module, and other applications can use the function modules that have been released. Based on this mechanism, the replacement of the platform itself, a variety of application components, it is very convenient for users.3) the system library and the Android runtimeLibrary system includes nine subsystems, respectively is the layer management, media library, SQLite, OpenGLEState, freetype, WebKit, SGL, SSL and libc, include core library and the Dalvik virtual machine running Android. The former is compatible with the most of the Java language to call the function, and includes the core library for Android, such as android.os, , android.media and so on. The latter is a Java virtual machine based on the register, the Dalvik virtual machine isthe important function of the completion of life cycle management, management of the stack, thread management, safe and exception management and garbage collection.4) Linux kernelAndroid core system services rely on the Linux2.6 kernel, such as security, memory management, process management, network protocol stack and driver model. Linux kernel is also used as the abstraction layer of the hardware and software stack. Driver: Binder (IPC) driver, flash memory driver, keyboard driver, WiFi driver, Audio driver, camera driver, display driver, power management, etc.2.Android released versionSince September 2008, Google released Android 1.0 system, which is the Android system the earliest version, over the next few years, Google with amazing speed constantly updated released Android system, 2.1, 2.2, 2.3 system launched the Android to occupy the market, a large number of. In February 2011, Google released Android 3.0 system, this system version is specifically for the tablet PC design, but also for Android version of the few failure, after the launch has not any improvement, market share is very few. But soon, in October of the same year, Google has released a Android 4.0 system, this system version no longer on mobile phones and tablet for differentiation between can Application on the phone can also be application in the plate, in addition is introduced many characteristics.So Android the current market usage? Analysis of Android user versions since December 2009. Until May 2014, Jelly's Bean Android was the most widely used version, accounting for 61% of all users.3.Android application features1 )major componentsAndroid four basic components are Activity, BroadcastReceiver radio receivers, Service services, Provider Content content providers.Activity: an application, a Activity is usually a separate screen, it can be displayed on the top of the control can also listen to and handle the user's response to the incident. Communication between Activity through Intent. In the description of the structure of the Intent, there are two most important parts: the action and action of the corresponding data.BroadcastReceive radio receiver, to: applications can use it to external events to filter only the interest of external events (such as when an incoming call, or network data when available) to receive and respond to. Broadcast receivers have no user interface. However, they can either start a activity or serice to respond to the information they receive, or NotificationManager to notify the user. Notice can be used in many ways to attract the attention of the user - flashing lights, shaking, playing sound, etc.. Generally put a persistent icon in the status bar, the user can open it and get the message.Service services: a Service is a long life cycle, there is no user interface procedures, can be used to develop such as monitoring procedures.Provider Content content provider: Android platform provides Provider Content to make an application specific data set available to other applications. These data can be stored in the file system, in an SQLite database, or in any other reasonable way, other applications can through the contentresolver class from the content provider access orstore data. (in application outsourcing a layer of shell).2) rich control systemAndroid system for developers to provide the rich system controls, we can write beautiful interface, can also through the expansion of system control, custom control to meet the needs of self, the common controls are: textview, Buttion, EditText, some of the layout of the controls.3) Persistence technologyAndroid system also comes with the SQLite database, SQLite database is a kind of lightweight, fast computing speed of the embedded relational database. It not only supports the standard SQL syntax, but also can be packaged by API good Android to operate, so that the storage and reading of data becomes very convenient.4 )locationMobile devices and PC compared to the location is a major highlight of the location, and now the basic Android phone is built in GPS, we can through the GPS, combined with our creativity, to create a LBS based products.5) powerful mediaProvides a rich multimedia services Android system, such as music, video, audio, pictures, alarm and other. All this all can be in the program through the code to control, make your application more rich and colorful.6 )sensorsAndroid phones built-in a variety of sensors, such as acceleration sensors, sensor orientation, which is one of the characteristics of mobile devices, we can flexibly using these sensors, can make a lot of can not be realized in PC applications. For example, "WeChat shake", "search song shake" and other functions.4 .Android development environmentDevelopment environment to build the software needed to focus on the introduction of several important tools: SDK Eclipse, Android, ADT.SDK1)AndroidAndroid SDK from Google Android development kit. In the Android development process, we need to refer to the toolkit, which contains the API for developing applications for Android.2)EclipseJava application development of the artifact, one of the best tools to use IDE, is characterized by open source, powerful plug-in function, can support a variety of language development. Of course in addition, Google also launched the Android studio, specifically tailored for Android program, but because Android studio just launched soon, less stable, after all, new tools or more, the eclipse is application has been very mature, a variety of online about the eclipse of difficult and complicated diseases solutions to many, compared to Android studio is relatively small.3)ADTADT name called "Android development tools," is Google to provide an eclipse plug-in, for providing a powerful, integrated the Android development environment in eclipse.5.Android program structure1)SRCThere is no doubt that the SRC directory is placed where we all Java code and themeanings of it here and ordinary Java projects under the SRC directory is exactly the same.2)GenIs automatically generated in this directory content, there are a R.Java file you in the project add any resources will in which to generate a corresponding resource ID, this file is not manual to modify it.3)assetsThis directory can be stored in a number of files packaged with the program, you can run the program to read the contents of these files dynamically. In addition, if you use the WebView to load the function of the local web page, all the pages related files are stored in this directory.4)binThis directory page does not need too much attention, it contains a number of automatically generated at compile time. Of course, will include a compiled installation package, the suffix for the.Apk file.5)LIBSIf the project is to use the third party jar package, you need to put these jar packages in the LIBS directory, in this directory will be automatically added to the jar package to build the path to go.6)resThis directory content is a bit more, simple point that is used in the project all the pictures, layout, string and other resources to stored in the directory, R.Java mentioned in the content is according to the directory file automatically generated. Of course, this directory there are a lot of sub directories, pictures on the drawable directory, the layout on the layout directory, under the values directory in the directory.7)AndroidManifest.xmlThis is the configuration file for the entire Android project, and all four major components you have defined in the program need to be registered in this file. In addition, you can add a permission declaration to the application, or you can specify the minimum compatible version and the target version you specify when you create a project.8)proguard-project.txtIn the release of your program, some APK files are easy to be anti compiler, so this time the file is played a role, used to confuse the program code, so that others are not so easy to see the source code.9)project.propertiesSpecifies the SDK version used by the compiler6.Logcat toolsLog in any project development process will play a very important role, in the Android project if you want to view the log must logcat tool to use.Android provides a log tool class is Log, a total of five levels, the class increment.1)Log.v ()This method is used to print the most trivial, meaning the smallest log information. Corresponding level verbose, is the lowest level of the Android log inside a.2)Log.d ()This method is used to print some debugging information, which should be helpful to your debugging process and analysis problems. The corresponding level debug, higher than the verbose level.3)Log.i ()This method is used to print some of the more important data, these data should be what you want to see, you can help you analyze the kind of user behavior. The corresponding level info, higher than the debug level.4)Log.w ()This method is used to print a number of warning messages, suggesting that the program may have a potential risk in this place, it is best to repair the place where these warnings appear. The corresponding level warn, higher than the info level.5)Log.e ()This method is used to error messages printed in the program, such as the program to the catch statement. When there is an error message printed out, the general representative of your program has serious problems, and must be repaired as soon as possible. The corresponding level error, higher than the warn level.7.Hello WorldThe default project created with Hello is World. Eclipse+ADT.对于安卓系统开发的介绍摘要Android系统是一种以Linux为基础的开放源码操作系统,主要使用于便携设备。
Application FundamentalsAndroid applications are written in the Java programming language. The compiled Java code —along with any data and resource files required by the application —is bundled by the aapt tool into an Android package, an archive file marked by an .apk suffix. This file is the vehicle for distributing the application and installing it on mobile devices; it's the file users download to their devices. All the code in a single .apk file is considered to be one application.Android应用基础:Android应用程序是通过java语言开发的,通过绑定一些应用所需要的东西,例如:编译的Java代码,加上数据和一些资源文件,使用一个apt的工具将所有的东西封装成一个android包,这个文件的文件后缀是.apk。
这个文件是分发并安装应用程序到移动设备的载体,是用户获得该应用程序所需要的下载的文件。
Application Components A central feature of Android is that one application can make use of elements of other applications (provided those applications permit it). For example, if your application needs to display a scrolling list of images and another application has developed a suitable scroller and made it available to others, you can call upon that scroller to do the work, rather than develop your own. Your application doesn't incorporate the code of the other application or link to it. Rather, it simply starts up that piece of the other application when the need arises. For this to work, the system must be able to start an application process when any part of it is needed, and instantiate the Java objects for that part. Therefore, unlike applications on most other systems, Android applications don't have a single entry point for everything in the application (no main() function, for example). Rather, they have essential components that the system can instantiate and run as needed. There are four types of components:Activities An activity presents a visual user interface for one focused endeavor the user can undertake. For example, an activity might present a list of menu items users can choose from or it might display photographs along with their captions. A text messaging application might have one activity that shows a list of contacts to send messages to, a second activity to write the message to the chosen contact, and other activities to review old messages or changesettings. Though they work together to form a cohesive user interface, each activity is independent of the others. Each one is implemented as a subclass of the Activity base class. An application might consist of just one activity or, like the text messaging application just mentioned, it may contain several. What the activities are, and how many there are depends, of course, on the application and its design. Typically, one of the activities is marked as the first one that should be presented to the user when the application is launched. Moving from one activity to another is accomplished by having the current activity start the next one. Android有四大应用程序组件Android的一个很重要的中心特征就是一个应用程序能充分利用其他的应用程序的一些组件(前提是被允许的)例如:如果的当前开发的应用需要一个滚动的列表去展示相片并且当时其他的程序已经开发了一个合适的滚动列表并且对其他人可用,你可以调用这个滚动的列表来完成你的工作而不是开发你自己的。
安卓单词(国外英文资料)在当今数字化的时代,安卓操作系统已经成为全球范围内使用最广泛的移动操作系统之一。
安卓不仅为用户提供了丰富的应用和功能,还推动了移动技术的创新和发展。
然而,对于许多人来说,安卓系统中的许多专业术语和概念可能显得有些陌生和难以理解。
为了帮助用户更好地了解安卓系统,本文将介绍一些与安卓相关的常用单词和术语,并提供相关的英文资料,以便读者能够更深入地了解安卓系统的各个方面。
1. Android:安卓操作系统的名称,源自于英文单词“android”,意为“”。
2. APK:安卓应用程序的安装包文件格式,全称为“Android Package”。
3. Dalvik:安卓系统中的一个虚拟机,用于运行安卓应用程序。
4. ROM:安卓系统的固件版本,全称为“ReadOnly Memory”。
5. Root:对安卓系统进行解锁,以获得更高的权限和更广泛的控制。
6. SDK:安卓软件开发工具包,全称为“Software Development Kit”。
7. UI:用户界面,全称为“User Interface”。
8. UX:用户体验,全称为“User Experience”。
9. Widget:安卓系统中的一个小工具,可以显示在主屏幕上,提供快捷的操作和显示信息。
10. Fragment:安卓系统中的一个组件,用于实现用户界面的模块化。
1. Android Developers:安卓开发者官方网站,提供了丰富的文档、教程和资源,适合开发者学习安卓编程。
2. XDA Developers:一个安卓社区,提供了大量的安卓相关资讯、教程和讨论,适合对安卓系统感兴趣的用户。
3. Android Central:一个专注于安卓系统的新闻网站,提供了最新的安卓资讯、评测和教程。
4. Stack Overflow:一个编程问答社区,提供了大量的安卓编程问题解答,适合开发者解决安卓编程中的问题。
5. Reddit:一个社交新闻网站,有一个专门的安卓子版块,提供了大量的安卓相关讨论和分享。
中英文翻译安卓应用开发基础在Java编程语言编写的Android应用程序的Android的SDK工具编译代码以及与任何数据和到一个Android的包,一个归档文件档案资源的.apk后缀,所有的在一个单一的代码.apk文件被认为是一个应用程序,是Android的文件,供电设备来安装应用程序。
一旦安装在设备上,每个Android应用程序的生命在它自己的安全沙箱:而Android操作系统是一个多用户Linux系统中,每个应用程序是一个不同的用户。
默认情况下,每个应用程序的系统分配一个唯一的Linux用户ID(该ID仅用于由系统是未知的应用程序),系统设置所有的应用程序中的文件权限,以便只有用户ID分配给该应用程序可以访问它们。
每个进程都有它自己的虚拟机(VM),因此应用程序的代码在从其他应用程序隔离运行。
默认情况下,每个应用程序运行在它自己的Linux进程。
Android的启动过程时,应用程序的任何组件需要被执行,然后关闭该进程时,它不再需要或恢复时,系统必须为其他应用程序的内存。
这样一来,Android系统实现了最小特权原则,也就是说,每个应用程序,默认情况下,只能访问的组件,它需要做的工作,没有更多,这将创建一个非常安全的环境,使应用程序无法访问的,这就是它没有给予许可制度的部分。
但是,有一个应用程序的方法与其他应用程序和应用程序访问系统服务的数据:这有可能为两个应用程序安排共享相同的Linux用户ID,在这种情况下,它们能够相互访问的文件。
为了节约使用相同的用户ID系统资源,应用程序还可以安排运行在相同的Linux进程和共享同一个VM(应用也必须使用相同的证书签名)。
应用程序可以请求访问权限,如用户的联系人,短信,可安装存储(SD卡),摄像头,蓝牙等设备的数据,所有应用程序的权限必须由用户在安装时授予。
这涵盖了基本就如何Android应用程序在系统中存在这个文件的其余部分向您介绍:1、框架的核心组件定义应用程序。
The thesis is a review paper that gives an introduction to the new mobile platform. Android as well as a comparative evaluation with regard to other mobile operating systems.The key topic of this thesis is the categorization of Android.Therefore it first gives a historical introduction to cell phones and mobile operating systems.Then it describes the main features of Android for a better understanding of this platform.In the following theoretical part Android will be compared to the mobile operating systems Symbian OS and Windows Mobile. Features and criteria defined in this part will be considered and included in the comparison of these systems.The practical part contains a comparison of the Software Development Kits (SDK) from Android and Symbian OS. In this context a simple application implementation on both systems is realized tosupport this comparison.Finally an outlook and a conclusion complete this elaboration.这是一篇介绍新的手机系统的论文,也将Android和其他手机操作系统进行了比较评价。
lder namedsrc. This is the source code folder for the given sample application. Youcan use this to view, edit,and recompile the code for any of the applications. Takeadvantage of this source code to learn some tricks and tips about the Android platform.Android ToolsThe Android SDK supplies developers with a number of powerful and useful tools.Throughoutthis book, you will use only a handful of them directly. This section takes aquick look at just afew of these tools, which will be covered in much more depth in thefollowing chapters, as youdive into command-line development.NOTEFor more detailed information about the other tools included in the Android SDK,consult the Android doc files.emulator.exeArguably one of the most important tools included in the Android SDK is emulator.exe.emulator.exe launches the Android Emulator. The Android Emulator is used toyou're yourapplications in a pseudo-Android environment. Given that, as of the writing of this book,therewere no hardware devices yet released for the Android platform, emulator.exe isgoing to be your only means to test applications on a “native” platform.You can run emulator.exe from the command line or execute it from within Eclipse.In this book, you’ll usually let Eclipse launch the Android Emulator environment for you.However, in theinterest of giving you all the information you need to program with theAndroid SDK outside of Eclipse, Chapter 6 covers command-line usage of emulator.exewhen you create your Hello World! applications.When using the Android Emulator to test your applications, you have two choices fornavigatingthe user interface. First, the emulator comes with usable buttons, as shown inFigure 4-1. You can use these buttons to navigate Android and any applications that youdevelop for the platform.TIPThe Power On/Off, V olume Up, and V olume Down buttons are slightly hidden to thesides of the virtual device. They identify themselves when you hover the mouse pointerover them.Given that many higher-end phones now include a touch screen, the second inputchoice you have when using the emulator is a simulated touch screen. You use yourmouse as a stylus. The objects on the emulator’s screen can be interacted with usingthe mouse.adb.exeAnother tool that will become very useful to you when you are using command-lineprogrammingis Android Debug Bridge or adb (adb.exe). This tool allows you to issuecommands to the Emulator.exe tool. When you are working in a command-lineenvironment, the adb tool allows you to do the following:● Start and stop the ser ver● Install and uninstall applications● Move files to and from the emulatorMKSDCARD.exeMKSDCARD.exe is a very useful tool if you are testing an application that will needto read orwrite files to or from an SD Memory Card inserted into the mobile device.MKSDCARD.execreates a small partition drive on your drive that will hold and retainthetest files. The emulatorwill treat this partition like an SD Memory Card.DX.exeDX.exe is the compiler of the Android SDK. When run against your Java files, DX.exewill createfiles with .dex extensions—Dalvik executable format. These files are in thecorrect format to beunderstood by, and run on, an Android device.NOTEAndroid executable files are called Dalvik executable files as a reference to the Dalvikvirtual machine that Android used to run all applications. The Dalvik virtual machineruns each application in its own thread with the same priority as core Androidapplications. activityCreator(.bat or .pn)activityCreator is a simple command-line tool that is used to set up a basic developmentenvironment. When run from the command line, activityCreator will set up the shell filesneeded to create a basic Android application. Having these shell files is especially usefulif you are not using Eclipse. The Android plugin for Eclipse sets up these shell files foryou by calling the activityCreator when you create a new project.Depending on what type of environment you are running, you will see theactivityCreator represented by a different type of script file. If you are in a Windowsenvironment, this will be a .bat file; otherwise it will be a python (.pn) script. Yousimply execute the script, which in turn calls the actual activityCreator process withthe correct parameters.APIsThe API, or application programming interface, is the core of the Android SDK. An APIis a collection of functions, methods, properties, classes, and libraries that is used byapplication developers to create programs that work on specific platforms. The AndroidAPI contains all thespecific information that you need to create applications that canwork on and interact with an Android-based application.The Android SDK also contains two supplementary sets of APIs—the Google APIsand the Optional APIs. Subsequent chapters will focus much more on these APIs as youbegin writingapplications that utilize them. For now, take a quick look at what theyinclude so that you are familiar with their uses.Google API sThe Google APIs are included in the Android SDK and contain the programmingreferences that allow you to tie your applications into existing Google services. If youare writing an Androidapplication and want to allow your user to access Google servicesthrough your application, you need to include the Google API.Located in the android.jar file, the Google API is contained within the com.google.*package. There are quite a few packages that are included with the Google API. Some ofthe packages that are shipped in the Google API include those for graphics, portability,contacts, and calendar utilities. However, the packages devoted to Google Maps will bethe primary focus in this book. Using the com.google.android.maps package, which contains information for GoogleMaps, you can create applications that interact seamlessly with the already familiarinterface of Google Maps. This one set of packages opens a whole world of usefulapplications just waiting to be created.The Google API also contains a useful set of packages that allows you to takeadvantage of the newer Extensible Messaging and Presence Protocol (XMPP) developedby the Jabber open source community. Using XMPP, applications can quickly becomeaware of other clients’ presence andavailability for the purpose of messaging andcommunications. The API packages dealing with XMPP are very useful if you wantto create a “chat”-style program that utilizes the phone messaging capabilities.Optional APIsThe Android SDK includes a number of Optional APIs that cover functionality notcovered by the standard Android APIs. These Optional APIs are considered optionalbecause they deal with functionality that may or may not be present on a given handsetdevice. That is, some devices created for the Android platform may include upgradesand features that others do not; the Optional APIs cover your programming optionswhen trying to utilize these features in your Android applications.One of these optional features (which you will use later in the book) is a cell-phone-basedGPS. The Android LBS (Location-Based Services) API deals with the functionalityneeded to receive and utilize informatio n from a device’s GPS unit. (Combine theinformation in the Android LBS API with that in the Google Maps API, and you mighthave a very useful application that can automatically display a map of where you arelocated at any given point in time.)Other Optional APIs include those for utilizing Bluetooth, Wi-Fi, playing MP3s, andaccessing 3-D—OpenGL-enable hardware.Application Life CycleIf you have a decent amount of experience as an application developer, you are familiarwith theconcept of an application life cycle. An application life cycle consists of thesteps that theapplication’s processes must follow from execution to termination. Everyapplication, regardless of the language it was written in, has a specific life cycle, andAndroid applications are no exception. This section examines the life cycle of an ASPapplication and compares that to an Android application’s life cycle.Standard ASP Application Life CycleThe life cycle of a standard ASP application is similar enough to that of an Androidapplication to make this a good comparison. ASP applications step through fivedistinct processes from launch to disposal. These steps are required to be implementedby all ASP applications, and really define what an ASP application is. The steps, inorder, are1. Application_Start2. Event3. HTTPApplication.Init4. Disposal5. Application_EndChapter 4: Exploring the Android SDK 4950 Android: A Programmer’s GuideTIPSome ASP reference materials consider Disposal and Application_End to be one stepin the life cycle. However, the Disposal call can be intercepted before it is passed toApplication_End. This can allow the application to perform specific functions beforeit is actually destroyed.Application_Start is called when the application is requested from the server. Thisprocess in turn leads into the Event process(es). When all associated application moduleshave loaded, HTTPApplication.Init is called. The application executes its events, andwhen the user attempts toclose it, Dispose is called. Dispose then passes processingon to the Application_End process, which closes the application.This is a fairly standard application life cycle. Most applications follow similar lifecycles: an application is created, loaded, has events, and is destroyed. The followingsection demonstrates how this compares to the Android application life cycle.Android Application Life CycleThe Android application life cycle is unique in that the system controls much of the lifecycle of the application. All Android applications, or Activities, are run within their ownprocess. All of the running processes are watched by Android and, depending on howthe activity is running (this is, a foreground activity, background activity, and so forth),Android may choose to end the activity to reclaim needed resources.NOTEWhen deciding whether an activity should be shut down, Android takes into accountseveral factors, such as user input, memory usage, and processing time.Some of the specific methods called during the life cycle of an android activity are● onC reate● onStart● Process-specific events (for example: launching activities or accessing a database)● onStop● onDestroyFollowing the same logic as other application life cycles, an Android applicationis created, the processes are started, events are fired, processes are stopped, and theapplication is destroyed. Though there are a few differences, many application developersshould be comfortable with the steps in the life cycle.文献出处:DiMarzio,J.F.Android: A Programmer's Guide[M].McGraw-Hill Prof Med/Tech, 2008:41-50NotePad写字板NotePad,允许你打开,创建并且编辑小的笔记。
android手机中英文对照上一篇/下一篇2011-01-2520:01:41/个人分类:学习中查看(83)/评论(0)/评分(0/0)Menuadd添加wallpaper壁纸search搜索notifications通知setting设置preference偏好设置(LauncherPro设置)》》》》》》》》》》》》》》》》》》》》》》》》》》》》Settingswireless&networks无线和网络airplane mode飞行模式(disable all wireless connections停用所有无线连接)Wi-Fi(turn on Wi-fi打开Wi-Fi)Wi-Fi settings(set up&manage wireless access points设置和管理无线连接接入点)Wi-Finetwork notification网络通知(notify me when an open network is available附近有开放网络时通知我)bluetooth(turn on bluetooth打开蓝牙)bluetooth settings蓝牙设置(manage connections,set device name&discoverability管理连接、设置设备名称和可检测性)bluetooth(turn on bluetooth打开蓝牙)device name设备名称(no name set,using account name为设置名称,使用账户名)discoverable可检测性(make device discoverable可以检测到设备)scan for devices扫描查找设备tethering绑定(share your phone's mobile data connection via USB将您手机的移动数据连接通过USB分享)USB tethering USB绑定help帮助VPN settings虚拟专用网设置(set up&manage virtual private networks(VPNs)设置和管理虚拟专用网)mobile networks移动网络(set options for roaming,networks,APNs设置漫游、网络、APN选项) data enabled启用数据(enable data access over mobile network启用移动网络的数据访问功能) data roaming数据漫游(connect to data services when raaming漫游时连接到数据服务)APN:acces point names接入点名称menu>new APN新建APN/reset to default重置为默认设置use only2G networks仅适用2G网络(saves battery省电)network operators网络运营商(select a network operator选择一个网络运营商)call settings通话设置crystaltalk setting摩托丽音设置(optimize in-call audio profile优化通话声音)fixed dialing numbers固定拨号(manage fixed dialing number管理固定拨号)voicemail语音信箱voicemail service语音信箱服务(my carrier我的运营商)voicemail settings语音信箱设置(settings for my carrier我的运营商设置)voicemial number语音信箱号码(not set未设置)always forward始终转接(disabled已停用)forward when busy占线时转接forword when unanswered无人接听时转接forword when unreachable无法接通时转接additional settings其他通话设置caller ID本机号码(use default operator settings to display my number in outgoing calls 外拨电话时按照运营商的默认设置来显示本机号码)call waiting来电等待(during a call,notify me of incoming calls在通话期间,通知我有其他来电)sound声音general常规silent mode静音模式(silence all sounds except media&alarms对所有非多媒体声音进行静音处理)vibrate震动(always始终/never一律不/only in silent mode仅在静音模式下来电震动/o nly when not in silent mode仅在非静音模式下来电震动)volume音量(use incoming call volume for notifications将来电音量用作通知音量)incoming calls来电phone ringtone手机铃声notification通知notification ringtone通知铃声feedback反馈audible touch tones按键操作音(play tones when using dial pad使用拨号键盘时播放按键音效)audible selection选择操作音(play sound when making screen selcction进行屏幕选择时播放音效)screen lock sounds屏幕锁定操作音(play sound when locking and unlocking the screen锁定和解锁屏幕时播放声音)haptic feedback触感(vibrate when pressing soft keys and on certain UI interactions按软键以及进行某些UI交互时震动)display显示brightness亮度(automatic brightness自动调节亮度)auto-rotate screen自动旋转屏幕animation动画(no window animations are shown不显示窗口动画-(no animations无动画/s ome animationgs部分动画/all animations所有动画))screen timeout屏幕超时(adjust the delay before the screen automatically turns off调整屏幕自动锁定前的延时)number of home panels屏幕个数(adjust the number of panels on home screen调整主屏的屏幕个数)location&security位置和安全my location我的位置use wireless network使用无线网络(location determined by Wi-Fi and/or mobile networks 通过Wi-Fi和/或移动网络确定的位置)use GPS satellites使用GPS卫星(locate to street-level(requires more battery plus view of sky)定位时,精确度设定为街道级别(取消选中可节约电量))phone lock手机锁定phone lock settings手机锁定设置phone lock type手机锁定类型(phone lock is off关闭手机锁定功能(none无/password 密码/pattern图案))change unlock password timeout更改解锁密码超时时间use visible pattern使用图案use tactile feedback使用触感screen unlock屏幕解锁set up screen lock设置屏幕锁定(lock screen with a pattern,PIN,or password使用图案、PI N或密码锁定屏幕)none无(disable screen unlock security停用屏幕锁定保护功能)pattern图案(draw pattern to unlock screen绘制图案给屏幕解锁)PIN(enter a number PIN to unlock screen输入数字PIN给屏幕解锁)(Personal Identification Number):个人识别码password密码(enter a password to unlcok screen输入密码给屏幕解锁) SIM card lock SIM卡锁定set up SIM card lock设置SIM卡锁定lock SIM card锁定SIM卡(require PIN to phone需要输入PIN才能使用手机)change SIM PIN更改SIM卡PINpassword密码visible passwords密码可见(show password as you type输入密码时可见)device administration设备管理select device admindtrators学则设备管理器(add or remove device administrators添加或删除设备管理器)(no available device administrators没有可供显示的设备管理器)credential strorage凭证存储use secure credentials使用安全凭证(allow applications to access secure certificates and ot her credentials允许应用程序访问安全凭证和其他凭证)install from SD card从SD卡安装(install encrypted certificates from SD card从SD卡安装加密的证书)(no certificate file found in the SD card在SD卡上找不到证书文件)set password设置密码(set or change the credential storage password设置或更改凭证存储密码)(set a password for the credenntial storage(at least8characters)设置凭证存储密码(至少8个字符)/new password新密码/confirm new password确认新密码)clear storage清楚存储(clear credential storage of all contents and reset its password清楚所有内容的凭证存储并重置其密码)applications应用程序unknown sources未知来源(allow installation of non-Market applications允许安装非电子市场提供的的应用程序)quick launch快速启动(set keyboard shortcuts to launch applictions设置快捷键启动程序)(no s hortcut没有快捷键)manage applications管理应用程序(manage and remove installed applications管理和删除按章的应用程序)(sort by size按大小排序)running services正在运行的服务(view and control currently running services查看和控制当前正在运行的服务)development开发(set options for application development设置应用程序开发选项)USB debugging USB调试(debug mode when USB is connected连接USB后启用调试模式) stay awake保持唤醒状态(screen will never sleep while charging充电时屏幕不会休眠)allow mock locations允许模拟地点(allow mock locations允许模拟地点)accounts&sync账户与同步(add account添加账户) general sync settings常规同步设置background data背景数据(applications can sync,send,and receive data at any time应用程序随时可以同步、发送和接收数据)auto-sync自动同步(applications sync data automatically应用程序自动同步数据)manage accounts管理账户(remove account删除账户)data&synchronization数据与同步sync contacts同步联系人(touch to sync now触摸可立即同步)sync gmail同步Gmailsync calendar同步日历privacy隐私权backup and restore备份和还原back up my data备份我的数据(back up my settings and other apppliction data备份我的设置和其他应用程序数据)automatic restore自动还原(if I reinstall an application,restore backed up settings or othe r data重新安装某个应用程序后,系统会还原已经备份的设置或其他数据)personal data个人数据factory data reset恢复出厂设置(erases all data on phone清除手机上的所有设置)SD card&phone storage SD卡和手机内存SD card SD卡total space总容量available space可用空间unmount/mount SD card卸载/安装SD卡(unmount the SD card for safe removal必须先卸载SD卡,才能将其安全移除)format SD card格式化SD卡(format(erase)the SD card格式化(清除)SD卡)internal phone storage手机内存available space可用空间language&keyboard语言和键盘select language选择语言multi-touch keyboard多点触摸键盘input languages输入语言(slide finger on spacebar to change language在空格键滑动手指可更改语言)on-screen keyboard屏幕键盘show suggestions显示建议(display corrections and completions while typing输入时启用联想提示)auto-correct errors自动纠错(spacebar and punctuation automatically insert highlighted w ord输入空格和标点时自动插入高亮词)auto-punctuate自动断句(press space twice to insert"."按两次空格插入“.”)vibrate on keypress按键时震动sound on keypress按键时播放音效auto-capitalization自动大写device keyboard侧滑键盘show suggestions显示建议(display completions while typing输入时启用联想功能)auto-correct error自动纠错(spacebar and punctuation automatically insert spelling correct ions输入空格和标点符号时自动插入拼写更正)voice input语音输入voice dictation语音命令(show speech recognition button for selected text fields为被选中的文本区显示语音识别按钮)preferred dictation engine默认引擎general settings常规设置highlight words高亮词(spacebar and punctuation highlights misspelled or unknown word s输入空格和标点使拼写错误或未知单词高亮显示)clear user dictionary(delete all learned words from the user dictionary)(are you sure you want to delete all learned words from the user dictionary?)device keyboard侧滑键盘(built-in keyboard settings内置键盘设置)auto-replace自动替换(correct mistype words更正错误输入)auto-cap自动大写(capitalize first letter in sentences句首单词大写)auto-punctuate自动短句(press space key twice to insert"."按两次空格插入“.”)auto-complete自动完成(spacebar and punctuation automatically insert hifhlighted word输入空格和标点时自动插入高亮词)use dictionary用户词典(you do not have any words in the user dictionary.you can add a wo rd through the menu.用户词典中没有您定义的字词。
外文资料和译文专业:计算机科学与技术(嵌入式软件开发方向)班级:计嵌入式000000姓名:XXXX学号:08111XXXXX指导教师:XXXX教授2011 年 12 月 18 日译文这篇文档主要讲述Android应用框架的核心原则。
站在高层来说,以用户为中心来设计良好的交互程序,对于应用设计者或是开发者来说是非常重要的。
下面用例子来阐述了activities和tasks的一些底层原则和机制,例如导航,多任务,activity重用,意图和activity栈。
这篇文档也着重讨论了一些设计决策,针对如何利用好它们去设计你的应用程序UI。
这篇文档中的例子均是Android应用程序,包括默认应用程序(比如拨号器)、Google 应用程序(比如地图)。
你可以自己在Android模拟器上或是Android手机上去试验这些例子。
如果你使用Android手机试验时,可能未提供本文档中的某些例子。
Applications, Activities, Activity Stack and Tasks 理解Android系统中的四个基本概念对你是很有帮助的,它们分别是:Applications(应用)Activities(活动)Activity Stack(活动堆栈)Tasks(任务)Applications一个Android应用程序其实就是由一个或者多个Activity组成。
它们被捆绑在一起并存放进.apk文件中,这就是Android应用程序。
Android中有着丰富的应用程序,比如邮件、日历、地图定位、文本消息、联系人、照相机、打电话、音乐播放器,系统设置等应用。
一般情况下,桌面上都会有Android应用程序快捷图标,用户可以选择某一个图标来启动应用程序。
ActivitiesActivity是Android应用程序的主要组成部分,activity可以是你自己创建的,当然,还可以是其它应用程序中的activity。
它们都是在运行时绑定上的,以便于应用程序扩展其自身的功能,它们一旦组合在一起,就会如同一个应用程序一样。
Android Application FundamentalsAndroid applications are written in the Java programming language. The Android SDK tools compile the code—along with any data and resource files—into an Android package, an archive file with an .apk suffix. All the code in a single .apk file is considered to be one application and is the file that Android-powered devices use to install the application.Once installed on a device, each Android application lives in its own security sandbox:The Android operating system is a multi-user Linux system in which each application is a different user.By default, the system assigns each application a unique Linux user ID (the ID is used only by the system and is unknown to the application). The system sets permissions for all the files in an application so that only the user ID assigned to that application can access them.Each process has its own virtual machine (VM), so an application's code runs in isolation from other applications.By default, every application runs in its own Linux process. Android starts the process when any of the application's components need to be executed, then shuts down the process when it's no longer needed or when the system must recover memory for other applications. In this way, the Android system implements the principle of least privilege. That is, each application, by default, has access only to the components that it requires to do its work and no more. This creates a very secure environment in which an application cannot access parts of the system for which it is not given permission.However, there are ways for an application to share data with other applications and for an application to access system services:It's possible to arrange for two applications to share the same Linux user ID, in which case they are able to access each other's files. To conserve system resources, applications with the same user ID can also arrange to run in the same Linux process and share the same VM (the applications must also be signed with the same certificate).An application can request permission to access device data such as the user's contacts, SMS messages, the mountable storage (SD card), camera, Bluetooth, and more. All application permissions must be granted by the user at install time.That covers the basics regarding how an Android application exists within the system. The rest of this document introduces you to:1、The core framework components that define your application.2、The manifest file in which you declare components and required device features for your application.3、Resources that are separate from the application code and allow your application to gracefully optimize its behavior for a variety of device configurations.Application ComponentsApplication components are the essential building blocks of an Android application. Each component is a different point through which the system can enter your application. Not all components are actual entry points for the user and some depend on each other, but each one exists as its own entity and plays a specific role—each one is a unique building block that helps define your application's overall behavior.There are four different types of application components. Each type serves a distinct purpose and has a distinct lifecycle that defines how the component is created and destroyed.Here are the four types of application components:ActivitiesAn activity represents a single screen with a user interface. For example, an email application might have one activity that shows a list of new emails, another activity to compose an email, and another activity for reading emails. Although the activities work together to form a cohesive user experience in the email application, each one is independent of the others. As such, a different application can start any one of these activities (if the email application allows it). For example, a camera application can start the activity in the email application that composes new mail, in order for the user to share a picture.An activity is implemented as a subclass of Activity and you can learn more about it in the Activities developer guide.ServicesA service is a component that runs in the background to perform long-running operations or to perform work for remote processes. A service does not provide a user interface. Forexample, a service might play music in the background while the user is in a different application, or it might fetch data over the network without blocking user interaction with an activity. Another component, such as an activity, can start the service and let it run or bind to it in order to interact with it.A service is implemented as a subclass of Service and you can learn more about it in the Services developer guide.Content providersA content provider manages a shared set of application data. You can store the data in the file system, an SQLite database, on the web, or any other persistent storage location your application can access. Through the content provider, other applications can query or even modify the data (if the content provider allows it). For example, the Android system provides a content provider that manages the user's contact information. As such, any application with the proper permissions can query part of the content provider (such as ContactsContract.Data) to read and write information about a particular person.Content providers are also useful for reading and writing data that is private to your application and not shared. For example, the Note Pad sample application uses a content provider to save notes.A content provider is implemented as a subclass of ContentProvider and must implement a standard set of APIs that enable other applications to perform transactions. For more information, see the Content Providers developer guide.Broadcast receiversA broadcast receiver is a component that responds to system-wide broadcast announcements. Many broadcasts originate from the system—for example, a broadcast announcing that the screen has turned off, the battery is low, or a picture was captured. Applications can also initiate broadcasts—for example, to let other applications know that some data has been downloaded to the device and is available for them to use. Although broadcast receivers don't display a user interface, they may create a status bar notification to alert the user when a broadcast event occurs. More commonly, though, a broadcast receiver is just a "gateway" to other components and is intended to do a very minimal amount of work. For instance, it might initiate a service to perform some work based on the event.A broadcast receiver is implemented as a subclass of BroadcastReceiver and each broadcast is delivered as an Intent object. For more information, see the BroadcastReceiver class.A unique aspect of the Android system design is that any application can start another application’s component. For example, if you want the user to capture a photo with the device camera, there's probably another application that does that and your application can use it, instead of developing an activity to capture a photo yourself. You don't need to incorporate or even link to the code from the camera application. Instead, you can simply start the activity in the camera application that captures a photo. When complete, the photo is even returned to your application so you can use it. To the user, it seems as if the camera is actually a part of your application.When the system starts a component, it starts the process for that application (if it's not already running) and instantiates the classes needed for the component. For example, if your application starts the activity in the camera application that captures a photo, that activity runs in the process that belongs to the camera application, not in your application's process. Therefore, unlike applications on most other systems, Android applications don't have a single entry point (there's no main()function, for example).Because the system runs each application in a separate process with file permissions that restrict access to other applications, your application cannot directly activate a component from another application. The Android system, however, can. So, to activate a component in another application, you must deliver a message to the system that specifies your intent to start a particular component. The system then activates the component for you.Activating ComponentsThree of the four component types—activities, services, and broadcast receivers—are activated by an asynchronous message called an intent. Intents bind individual components to each other at runtime (you can think of them as the messengers that request an action from other components), whether the component belongs to your application or another.An intent is created with an Intent object, which defines a message to activate either a specific component or a specific type of component—an intent can be either explicit or implicit, respectively.For activities and services, an intent defines the action to perform (for example, to "view" or "send" something) and may specify the URI of the data to act on (among other things that the component being started might need to know). For example, an intent might convey a request for an activity to show an image or to open a web page. In some cases, you can start an activity to receive a result, in which case, the activity also returns the result in an Intent (for example, you can issue an intent to let the user pick a personal contact and have it returned to you—the return intent includes a URI pointing to the chosen contact).For broadcast receivers, the intent simply defines the announcement being broadcast (for example, a broadcast to indicate the device battery is low includes only a known action string that indicates "battery is low").The other component type, content provider, is not activated by intents. Rather, it is activated when targeted by a request from a ContentResolver. T he content resolver handles all direct transactions with the content provider so that the component that's performing transactions with the provider doesn't need to and instead calls methods onthe ContentResolver object. This leaves a layer of abstraction between the content provider and the component requesting information (for security).There are separate methods for activating each type of component:You can start an activity (or give it something new to do) by passingan Intent to startActivity() or startActivityForResult() (when you want the activity to return a result).You can start a service (or give new instructions to an ongoing service) by passingan Intent to startService(). Or you can bind to the service by passing an Intent to bindService().You can initiate a broadcast by passing an Intent to methodslike sendBroadcast(), sendOrderedBroadcast(), or sendStickyBroadcast().You can perform a query to a content provider by calling query() on a ContentResolver.For more information about using intents, see the Intents and Intent Filters document. More information about activating specific components is also provided in the following documents: Activities, Services, BroadcastReceiver and Content Providers.Declaring componentsThe primary task of the manifest is to inform the system about the application's components. For example, a manifest file can declare an activity as follows:In the <application> element, the android:icon attribute points to resources for an icon that identifies the application.In the <activity> element, the android:name at tribute specifies the fu lly qualified class name of the Activity subclass and the android:label attributes specifies a string to use as the user-visible label for the activity.You must declare all application components this way:1、<activity>elements for activities2、<service> elements for services3、<receiver>elements for broadcast receivers4、<provider>elements for content providersActivities, services, and content providers that you include in your source but do not declare in the manifest are not visible to the system and, consequently, can never run.However, broadcast receivers can be either declared in the manifest or created dynamically in code (as BroadcastReceiver objects) and registered with the system bycalling registerReceiver().Declaring component capabilitiesAs discussed above, in Activating Components, you can use an Intent to start activities, services, and broadcast receivers. You can do so by explicitly naming the target component (using the component class name) in the intent. However, the real power of intents lies in the concept of intent actions. With intent actions, you simply describe the type of action you want to perform (and optionally, the data upon which you’d like to perform the action) and allow the system to find a component on the device that can perform the action and start it. If there are multiple components that can perform the action described by the intent, then the user selects which one to use.The way the system identifies the components that can respond to an intent is by comparing the intent received to the intent filters provided in the manifest file of other applications on the device.When you declare a component in your application's manifest, you can optionally include intent filters that declare the capabilities of the component so it can respond to intents from other applications. You can declare an intent filter for your component by addingan <intent-filter>element as a child of the component's declaration element.For example, an email application with an activity for composing a new email might declare an intent filter in its manifest entry to respond to "send" intents (in order to send email). An activity in your application can then create an intent with the “send” action (ACTION_SEND), which t he system matches to the email application’s “send” activity and launches it when you invoke the intent with startActivity().For more about creating intent filters, see the Intents and Intent Filters document.Declaring application requirementsThere are a variety of devices powered by Android and not all of them provide the same features and capabilities. In order to prevent your application from being installed on devicesthat lack features needed by your application, it's important that you clearly define a profile for the types of devices your application supports by declaring device and software requirements in your manifest file. Most of these declarations are informational only and the system does not read them, but external services such as Google Play do read them in order to provide filtering for users when they search for applications from their device.For example, if your application requires a camera and uses APIs introduced in Android 2.1 (API Level 7), you should declare these as requirements in your manifest file. That way, devices that do not have a camera and have an Android version lower than 2.1 cannot install your application from Google Play.However, you can also declare that your application uses the camera, but doesnot require it. In that case, your application must perform a check at runtime to determine if the device has a camera and disable any features that use the camera if one is not available.Here are some of the important device characteristics that you should consider as you design and develop your application:Screen size and densityIn order to categorize devices by their screen type, Android defines two characteristics for each device: screen size (the physical dimensions of the screen) and screen density (the physical density of the pixels on the screen, or dpi—dots per inch). To simplify all the different types of screen configurations, the Android system generalizes them into select groups that make them easier to target.The screen sizes are: small, normal, large, and extra large.The screen densities are: low density, medium density, high density, and extra high density.By default, your application is compatible with all screen sizes and densities, because the Android system makes the appropriate adjustments to your UI layout and image resources. However, you should create specialized layouts for certain screen sizes and provide specialized images for certain densities, using alternative layout resources, and by declaring in your manifest exactly which screen sizes your application supports withthe <supports-screens> element.For more information, see the Supporting Multiple Screens document.Input configurationsMany devices provide a different type of user input mechanism, such as a hardware keyboard, a trackball, or a five-way navigation pad. If your application requires a particular kind of input hardware, then you should declare it in your manifest with the <uses-configuration> e lement. However, it is rare that an application should require a certain input configuration.Device featuresThere are many hardware and software features that may or may not exist on a given Android-powered device, such as a camera, a light sensor, bluetooth, a certain version of OpenGL, or the fidelity of the touchscreen. You should never assume that a certain feature is available on all Android-powered devices (other than the availability of the standard Android library), so you should declare any features used by your application with the <uses-feature> element.Platform VersionDifferent Android-powered devices often run different versions of the Android platform, such as Android 1.6 or Android 2.3. Each successive version often includes additional APIs not available in the previous version. In order to indicate which set of APIs are available, each platform version specifies an API Level (for example, Android 1.0 is API Level 1 and Android 2.3 is API Level 9). If you use any APIs that were added to the platform after version 1.0, you should declare the minimum API Level in which those APIs were introduced using the <uses-sdk> element.It's important that you declare all such requirements for your application, because, when you distribute your application on Google Play, the store uses these declarations to filter which applications are available on each device. As such, your application should be available only to devices that meet all your application requirements.For more information about how Google Play filters applications based on these (and other) requirements, see the Filters on Google Play document.Application ResourcesAn Android application is composed of more than just code—it requires resources that are separate from the source code, such as images, audio files, and anything relating to the visual presentation of the application. For example, you should define animations, menus, styles, colors, and the layout of activity user interfaces with XML files. Using application resources makes it easy to update various characteristics of your application without modifying code and—by providing sets of alternative resources—enables you to optimize your application for a variety of device configurations (such as different languages and screen sizes).For every resource that you include in your Android project, the SDK build tools define a unique integer ID, which you can use to reference the resource from your application code or from other resources defined in XML. For example, if your application c ontains an image file named logo.png (saved in the res/drawable/ directory), the SDK tools generate a resource ID named R.drawable.logo, which you can use to reference the image and insert it in your user interface.One of the most important aspects of providing resources separate from your source code is the ability for you to provide alternative resources for different device configurations. For example, by defining UI strings in XML, you can translate the strings into other languages and save those strings in separate files. Then, based on a language qualifier that you append to the resource directory's name (such as res/values-fr/for French string values) and the user's language setting, the Android system applies the appropriate language strings to your UI.Android supports many different qualifiers for your alternative resources. The qualifier is a short string that you include in the name of your resource directories in order to define the device configuration for which those resources should be used. As another example, you should often create different layouts for your activities, depending on the device's screen orientation and size. For example, when the device screen is in portrait orientation (tall), you might want a layout with buttons to be vertical, but when the screen is in landscape orientation (wide), the buttons should be aligned horizontally. To change the layout depending on the orientation, you can define two different layouts and apply the appropriate qualifier to each layout's directory name. Then, the system automatically applies the appropriate layout depending on the current device orientation.For more about the different kinds of resources you can include in your application and how to create alternative resources for various device configurations, see the Application Resources developer guide.安卓应用基础在Java编程语言编写的Android应用程序的Android的SDK工具编译代码以及与任何数据和到一个Android的包,一个归档文件档案资源的.apk后缀,所有的在一个单一的代码.apk文件被认为是一个应用程序,是Android的文件,供电设备来安装应用程序。
Android系统外文翻译What is Android?For a while。
nal。
n developers have had the luxury of being able to create almost any kind of n they can XXX。
this is not tosay that nal。
n development is easier than other forms of development。
As someone who got their start in。
programming。
I include myself in this grouping.XXX with the。
operating system and underlying hardware pretty freely。
or XXX。
This kind of freedom to program independently has never really been available to the small group of programmers who XXX.Overall。
Android is a mobile operating system that allows XXX for mobile devices。
It has opened up a whole new world of possibilities for developers who want to create XXX underlying hardware of mobile devices。
With Android。
developers XXX。
from tracking XXX.Cell phone developers used to be a small group XXX。
and web development。
Android Application FundamentalsAndroid applications are written in the Java programming language. The Android SDK tools compile the code—along with any data and resource files—into an Android package, an archive file with an .apk suffix. All the code in a single .apk file is considered to be one application and is the file that Android-powered devices use to install the application.Once installed on a device, each Android application lives in its own security sandbox:The Android operating system is a multi-user Linux system in which each application is a different user.By default, the system assigns each application a unique Linux user ID (the ID is used only by the system and is unknown to the application). The system sets permissions for all the files in an application so that only the user ID assigned to that application can access them.Each process has its own virtual machine (VM), so an application's code runs in isolation from other applications.By default, every application runs in its own Linux process. Android starts the process when any of the application's components need to be executed, then shuts down the process when it's no longer needed or when the system must recover memory for other applications. In this way, the Android system implements the principle of least privilege. That is, each application, by default, has access only to the components that it requires to do its work and no more. This creates a very secure environment in which an application cannot access parts of the system for which it is not given permission.However, there are ways for an application to share data with other applications and for an application to access system services:It's possible to arrange for two applications to share the same Linux user ID, in which case they are able to access each other's files. To conserve system resources, applications with the same user ID can also arrange to run in the same Linux process and share the same VM (the applications must also be signed with the same certificate).An application can request permission to access device data such as the user's contacts, SMS messages, the mountable storage (SD card), camera, Bluetooth, and more. All application permissions must be granted by the user at install time.That covers the basics regarding how an Android application exists within the system. The rest of this document introduces you to:1、The core framework components that define your application.2、The manifest file in which you declare components and required device features for your application.3、Resources that are separate from the application code and allow your application to gracefully optimize its behavior for a variety of device configurations.Application ComponentsApplication components are the essential building blocks of an Android application. Each component is a different point through which the system can enter your application. Not all components are actual entry points for the user and some depend on each other, but each one exists as its own entity and plays a specific role—each one is a unique building block that helps define your application's overall behavior.There are four different types of application components. Each type serves a distinct purpose and has a distinct lifecycle that defines how the component is created and destroyed.Here are the four types of application components:ActivitiesAn activity represents a single screen with a user interface. For example, an email application might have one activity that shows a list of new emails, another activity to compose an email, and another activity for reading emails. Although the activities work together to form a cohesive user experience in the email application, each one is independent of the others. As such, a different application can start any one of these activities (if the email application allows it). For example, a camera application can start the activity in the email application that composes new mail, in order for the user to share a picture.An activity is implemented as a subclass of Activity and you can learn more about it in the Activities developer guide.ServicesA service is a component that runs in the background to perform long-running operations or to perform work for remote processes. A service does not provide a user interface. Forexample, a service might play music in the background while the user is in a different application, or it might fetch data over the network without blocking user interaction with an activity. Another component, such as an activity, can start the service and let it run or bind to it in order to interact with it.A service is implemented as a subclass of Service and you can learn more about it in the Services developer guide.Content providersA content provider manages a shared set of application data. You can store the data in the file system, an SQLite database, on the web, or any other persistent storage location your application can access. Through the content provider, other applications can query or even modify the data (if the content provider allows it). For example, the Android system provides a content provider that manages the user's contact information. As such, any application with the proper permissions can query part of the content provider (such as ContactsContract.Data) to read and write information about a particular person.Content providers are also useful for reading and writing data that is private to your application and not shared. For example, the Note Pad sample application uses a content provider to save notes.A content provider is implemented as a subclass of ContentProvider and must implement a standard set of APIs that enable other applications to perform transactions. For more information, see the Content Providers developer guide.Broadcast receiversA broadcast receiver is a component that responds to system-wide broadcast announcements. Many broadcasts originate from the system—for example, a broadcast announcing that the screen has turned off, the battery is low, or a picture was captured. Applications can also initiate broadcasts—for example, to let other applications know that some data has been downloaded to the device and is available for them to use. Although broadcast receivers don't display a user interface, they may create a status bar notification to alert the user when a broadcast event occurs. More commonly, though, a broadcast receiver is just a "gateway" to other components and is intended to do a very minimal amount of work. For instance, it might initiate a service to perform some work based on the event.A broadcast receiver is implemented as a subclass of BroadcastReceiver and each broadcast is delivered as an Intent object. For more information, see the BroadcastReceiver class.A unique aspect of the Android system design is that any application can start another application’s component. For example, if you want the user to capture a photo with the device camera, there's probably another application that does that and your application can use it, instead of developing an activity to capture a photo yourself. You don't need to incorporate or even link to the code from the camera application. Instead, you can simply start the activity in the camera application that captures a photo. When complete, the photo is even returned to your application so you can use it. To the user, it seems as if the camera is actually a part of your application.When the system starts a component, it starts the process for that application (if it's not already running) and instantiates the classes needed for the component. For example, if your application starts the activity in the camera application that captures a photo, that activity runs in the process that belongs to the camera application, not in your application's process. Therefore, unlike applications on most other systems, Android applications don't have a single entry point (there's no main()function, for example).Because the system runs each application in a separate process with file permissions that restrict access to other applications, your application cannot directly activate a component from another application. The Android system, however, can. So, to activate a component in another application, you must deliver a message to the system that specifies your intent to start a particular component. The system then activates the component for you.Activating ComponentsThree of the four component types—activities, services, and broadcast receivers—are activated by an asynchronous message called an intent. Intents bind individual components to each other at runtime (you can think of them as the messengers that request an action from other components), whether the component belongs to your application or another.An intent is created with an Intent object, which defines a message to activate either a specific component or a specific type of component—an intent can be either explicit or implicit, respectively.For activities and services, an intent defines the action to perform (for example, to "view" or "send" something) and may specify the URI of the data to act on (among other things that the component being started might need to know). For example, an intent might convey a request for an activity to show an image or to open a web page. In some cases, you can start an activity to receive a result, in which case, the activity also returns the result in an Intent (for example, you can issue an intent to let the user pick a personal contact and have it returned to you—the return intent includes a URI pointing to the chosen contact).For broadcast receivers, the intent simply defines the announcement being broadcast (for example, a broadcast to indicate the device battery is low includes only a known action string that indicates "battery is low").The other component type, content provider, is not activated by intents. Rather, it is activated when targeted by a request from a ContentResolver. T he content resolver handles all direct transactions with the content provider so that the component that's performing transactions with the provider doesn't need to and instead calls methods onthe ContentResolver object. This leaves a layer of abstraction between the content provider and the component requesting information (for security).There are separate methods for activating each type of component:You can start an activity (or give it something new to do) by passingan Intent to startActivity() or startActivityForResult() (when you want the activity to return a result).You can start a service (or give new instructions to an ongoing service) by passingan Intent to startService(). Or you can bind to the service by passing an Intent to bindService().You can initiate a broadcast by passing an Intent to methodslike sendBroadcast(), sendOrderedBroadcast(), or sendStickyBroadcast().You can perform a query to a content provider by calling query() on a ContentResolver.For more information about using intents, see the Intents and Intent Filters document. More information about activating specific components is also provided in the following documents: Activities, Services, BroadcastReceiver and Content Providers.Declaring componentsThe primary task of the manifest is to inform the system about the application's components. For example, a manifest file can declare an activity as follows:In the <application> element, the android:icon attribute points to resources for an icon that identifies the application.In the <activity> element, the android:name at tribute specifies the fu lly qualified class name of the Activity subclass and the android:label attributes specifies a string to use as the user-visible label for the activity.You must declare all application components this way:1、<activity>elements for activities2、<service> elements for services3、<receiver>elements for broadcast receivers4、<provider>elements for content providersActivities, services, and content providers that you include in your source but do not declare in the manifest are not visible to the system and, consequently, can never run.However, broadcast receivers can be either declared in the manifest or created dynamically in code (as BroadcastReceiver objects) and registered with the system bycalling registerReceiver().Declaring component capabilitiesAs discussed above, in Activating Components, you can use an Intent to start activities, services, and broadcast receivers. You can do so by explicitly naming the target component (using the component class name) in the intent. However, the real power of intents lies in the concept of intent actions. With intent actions, you simply describe the type of action you want to perform (and optionally, the data upon which you’d like to perform the action) and allow the system to find a component on the device that can perform the action and start it. If there are multiple components that can perform the action described by the intent, then the user selects which one to use.The way the system identifies the components that can respond to an intent is by comparing the intent received to the intent filters provided in the manifest file of other applications on the device.When you declare a component in your application's manifest, you can optionally include intent filters that declare the capabilities of the component so it can respond to intents from other applications. You can declare an intent filter for your component by addingan <intent-filter>element as a child of the component's declaration element.For example, an email application with an activity for composing a new email might declare an intent filter in its manifest entry to respond to "send" intents (in order to send email). An activity in your application can then create an intent with the “send” action (ACTION_SEND), which t he system matches to the email application’s “send” activity and launches it when you invoke the intent with startActivity().For more about creating intent filters, see the Intents and Intent Filters document.Declaring application requirementsThere are a variety of devices powered by Android and not all of them provide the same features and capabilities. In order to prevent your application from being installed on devicesthat lack features needed by your application, it's important that you clearly define a profile for the types of devices your application supports by declaring device and software requirements in your manifest file. Most of these declarations are informational only and the system does not read them, but external services such as Google Play do read them in order to provide filtering for users when they search for applications from their device.For example, if your application requires a camera and uses APIs introduced in Android 2.1 (API Level 7), you should declare these as requirements in your manifest file. That way, devices that do not have a camera and have an Android version lower than 2.1 cannot install your application from Google Play.However, you can also declare that your application uses the camera, but doesnot require it. In that case, your application must perform a check at runtime to determine if the device has a camera and disable any features that use the camera if one is not available.Here are some of the important device characteristics that you should consider as you design and develop your application:Screen size and densityIn order to categorize devices by their screen type, Android defines two characteristics for each device: screen size (the physical dimensions of the screen) and screen density (the physical density of the pixels on the screen, or dpi—dots per inch). To simplify all the different types of screen configurations, the Android system generalizes them into select groups that make them easier to target.The screen sizes are: small, normal, large, and extra large.The screen densities are: low density, medium density, high density, and extra high density.By default, your application is compatible with all screen sizes and densities, because the Android system makes the appropriate adjustments to your UI layout and image resources. However, you should create specialized layouts for certain screen sizes and provide specialized images for certain densities, using alternative layout resources, and by declaring in your manifest exactly which screen sizes your application supports withthe <supports-screens> element.For more information, see the Supporting Multiple Screens document.Input configurationsMany devices provide a different type of user input mechanism, such as a hardware keyboard, a trackball, or a five-way navigation pad. If your application requires a particular kind of input hardware, then you should declare it in your manifest with the <uses-configuration> e lement. However, it is rare that an application should require a certain input configuration.Device featuresThere are many hardware and software features that may or may not exist on a given Android-powered device, such as a camera, a light sensor, bluetooth, a certain version of OpenGL, or the fidelity of the touchscreen. You should never assume that a certain feature is available on all Android-powered devices (other than the availability of the standard Android library), so you should declare any features used by your application with the <uses-feature> element.Platform VersionDifferent Android-powered devices often run different versions of the Android platform, such as Android 1.6 or Android 2.3. Each successive version often includes additional APIs not available in the previous version. In order to indicate which set of APIs are available, each platform version specifies an API Level (for example, Android 1.0 is API Level 1 and Android 2.3 is API Level 9). If you use any APIs that were added to the platform after version 1.0, you should declare the minimum API Level in which those APIs were introduced using the <uses-sdk> element.It's important that you declare all such requirements for your application, because, when you distribute your application on Google Play, the store uses these declarations to filter which applications are available on each device. As such, your application should be available only to devices that meet all your application requirements.For more information about how Google Play filters applications based on these (and other) requirements, see the Filters on Google Play document.Application ResourcesAn Android application is composed of more than just code—it requires resources that are separate from the source code, such as images, audio files, and anything relating to the visual presentation of the application. For example, you should define animations, menus, styles, colors, and the layout of activity user interfaces with XML files. Using application resources makes it easy to update various characteristics of your application without modifying code and—by providing sets of alternative resources—enables you to optimize your application for a variety of device configurations (such as different languages and screen sizes).For every resource that you include in your Android project, the SDK build tools define a unique integer ID, which you can use to reference the resource from your application code or from other resources defined in XML. For example, if your application c ontains an image file named logo.png (saved in the res/drawable/ directory), the SDK tools generate a resource ID named R.drawable.logo, which you can use to reference the image and insert it in your user interface.One of the most important aspects of providing resources separate from your source code is the ability for you to provide alternative resources for different device configurations. For example, by defining UI strings in XML, you can translate the strings into other languages and save those strings in separate files. Then, based on a language qualifier that you append to the resource directory's name (such as res/values-fr/for French string values) and the user's language setting, the Android system applies the appropriate language strings to your UI.Android supports many different qualifiers for your alternative resources. The qualifier is a short string that you include in the name of your resource directories in order to define the device configuration for which those resources should be used. As another example, you should often create different layouts for your activities, depending on the device's screen orientation and size. For example, when the device screen is in portrait orientation (tall), you might want a layout with buttons to be vertical, but when the screen is in landscape orientation (wide), the buttons should be aligned horizontally. To change the layout depending on the orientation, you can define two different layouts and apply the appropriate qualifier to each layout's directory name. Then, the system automatically applies the appropriate layout depending on the current device orientation.For more about the different kinds of resources you can include in your application and how to create alternative resources for various device configurations, see the Application Resources developer guide.安卓应用基础在Java编程语言编写的Android应用程序的Android的SDK工具编译代码以及与任何数据和到一个Android的包,一个归档文件档案资源的.apk后缀,所有的在一个单一的代码.apk文件被认为是一个应用程序,是Android的文件,供电设备来安装应用程序。