Android software development: Difference between revisions

Content deleted Content added
Dcxf (talk | contribs)
Reorder sections
Dcxf (talk | contribs)
Basic lead
Line 1:
'''Android software development''' is the process by which new applications are created for the [[Android (operating system)|Android operating system]]. Applications are usually developed in the Java language using the Android Software Development Kit, but other development tools are available. As of April 2011 more than 200,000 applications have been developed for Android, with over 3 billion downloads.<ref name="200,000">{{cite web |title=Android App Stats|url=http://www.androlib.com/appstats.aspx|accessdate=31 December 2010}}</ref><ref>{{cite web |url= http://techcrunch.com/2011/04/14/google-3-billion-android-apps-installed-up-50-percent-from-last-quarter/ |title=Google: 3 Billion Android Apps Installed; Downloads Up 50 Percent From Last Quarter |author=Leena Rao|work=Techcrunch|date=14 April 2011|accessdate=13 May 2011}}</ref>
'''Android software development''' is the process by which new applications are created for the [[Android (operating system)|Android operating system]].
 
==Software development tools==
===Android SDK===
The Android [[software development kit]] (SDK) includes a comprehensive set of development tools.<ref>{{cite web |url = http://developer.android.com/guide/developing/tools/index.html |title = Tools Overview |work = Android Developers |date = 21 July 2009}}</ref> These include a [[debugger]], [[Software library|libraries]], a handset [[emulator]] (based on [[QEMU]]), documentation, sample code, and tutorials. The SDK is downloadable on the [http://developer.android.com/sdk/index.html Android developer website]. Currently supported development platforms include computers running [[Linux kernel|Linux]] (any modern desktop [[List of GNU/Linux distributions|Linux distribution]]), [[Mac OS X]] 10.4.9 or later, [[Windows XP]] or later. The officially supported [[integrated development environment]] (IDE) is [[Eclipse (software)|Eclipse]] (currently 3.5 or 3.6) using the Android Development Tools (ADT) Plugin, though developers may use any text editor to edit Java and XML files then use [[command line]] tools ([[Java Development Kit]] and [[Apache Ant]] are required) to create, build and debug Android applications as well as control attached Android devices (e.g., triggering a reboot, installing software package(s) remotely).<ref>{{cite web |url = http://jonwestfall.com/2009/08/backup-restore-android-apps-using-adb/ |title = Backup & Restore Android Apps Using ADB |first = Jon |last = Westfall |date = 25 August 2009 |work = JonWestfall.com |accessdate =2009-12-07}}</ref>
 
Line 8 ⟶ 9:
Android applications are packaged in [[APK (file format)|.apk]] format and stored under <code>/data/app</code> folder on the Android OS (the folder is accessible to root user only for security reasons). APK package contains .dex files<ref>{{cite web |url=http://developer.android.com/guide/appendix/glossary.html |title=Android SDK Glossary}}</ref> (compiled byte code files called [[Dalvik Virtual Machine|Dalvik]] executables), resource files, etc.
 
===Native codeDevelopment Kit===
Libraries written in [[C (programming language)|C]] and other languages can be compiled to [[ARM architecture|ARM]] [[native code]] and installed using the Android [[Native Development Kit]]. Native classes can be called from Java code running under the Dalvik VM using the <code>System.loadLibrary</code> call, which is part of the standard Android Java classes.<ref>{{cite web |url=http://davanum.wordpress.com/2007/12/09/android-invoke-jni-based-methods-bridging-cc-and-java/ |title=Android&nbsp;— Invoke JNI based methods (Bridging C/C++ and Java) |last=Srinivas |first=Davanum |date=2007-12-09 |accessdate=2008-12-13}}</ref><ref>{{cite web |url=http://developer.android.com/reference/java/lang/System.html |title=java.lang.System |work=Android Developers |accessdate=2009-09-03}}</ref>
 
Complete applications can be [[Compiler|compiled]] and installed using traditional development tools.<ref name="benno">{{cite web |url=http://benno.id.au/blog/2007/11/13/android-native-apps |title=Native C application for Android |date=13 November 2007|work=Benno's blog|first=Ben |last=Leslie |accessdate=2009-09-04}}</ref> The ADB debugger gives a root shell under the Android Emulator which allows native [[ARM architecture|ARM code]] to be uploaded and executed. ARM code can be compiled using [[GNU Compiler Collection|GCC]] on a standard PC.<ref name="benno"/> Running native code is complicated by the fact that Android uses a non-standard C library (libc, known as [[Bionic (software)|Bionic]]). The underlying graphics device is available as a [[framebuffer]] at ''/dev/graphics/fb0''.<ref>{{cite mailing list |url=http://groups.google.com/group/android-developers/msg/ace258af92fff692?dmode=source&pli=1 |title=Native C *GRAPHICAL* applications now working on Android emulator |last=Cooksey |first=Tom |mailinglist=android-developers |date=2007-11-07 |accessdate=2008-12-13}}</ref> The graphics library that Android uses to arbitrate and control access to this device is called the [[Skia Graphics Engine|Skia Graphics Library]] (SGL), and it has been released under an open source license.<ref>{{cite web|url=http://src.chromium.org/viewvc/chrome/trunk/src/skia/|title=Skia source}}</ref> Skia has backends for both [[win32]] and [[Unix]], allowing the development of cross-platform applications, and it is the graphics engine underlying the [[Google Chrome]] web browser.<ref>{{cite web |url=http://www.atoker.com/blog/2008/09/06/skia-graphics-library-in-chrome-first-impressions/ |title=Skia graphics library in Chrome: First impressions |last=Toker |first=Alp |date=2008-09-06 |accessdate=2008-12-13}}</ref>
 
===App Inventor for Android===
{{Main|Google App Inventor}}
On 12 July 2010 Google announced the availability of App Inventor for Android, a Web-based visual development environment for novice programmers, based on MIT's Open Blocks Java library and providing access to Android devices' GPS, accelerometer and orientation data, phone functions, text messaging, speech-to-text conversion, contact data, persistent storage, and Web services, initially including Amazon and Twitter.<ref>{{cite news |last=Claburn |first=Thomas |title=Google App Inventor Simplifies Android Programming |url=http://www.informationweek.com/news/smb/mobile/showArticle.jhtml?articleID=225702880&subSection=News |accessdate=2010-07-12 |newspaper=Information Week |date=2010-07-12}}</ref> "We could only have done this because Android’s architecture is so open," said the project director, MIT's [[Hal Abelson]].<ref>{{cite news |last=Lohr |first=Steve |title=Google’s Do-It-Yourself App Creation Software |url=http://www.nytimes.com/2010/07/12/technology/12google.html?src=busln |accessdate=2010-07-12 |newspaper=New York Times |date=2010-07-11}}</ref> Under development for over a year,<ref>{{cite news |last=Abelson |first=Hal |title=App Inventor for Android|url=http://googleresearch.blogspot.com/2009/07/app-inventor-for-android.html |accessdate=2010-07-12 |newspaper=Google Research Blog |date=2009-07-31}}</ref> the block-editing tool has been taught to non-majors in computer science at Harvard, MIT, Wellesley, and the University of San Francisco, where Professor David Wolber developed an introductory computer science course and tutorial book for non-computer science students based on App Inventor for Android.<ref>{{cite news |last=Kim|first=Ryan |title=Google brings app-making to the masses |url=http://articles.sfgate.com/2009-12-11/business/17220628_1_computer-science-smart-phone-android |accessdate=2010-07-12 |newspaper=San Francisco Chronicle |date=2009-12-11}}</ref><ref>{{cite web |last=Wolber |first=David |title=AppInventor.org |url=http://www.appinventor.org/ |accessdate=2010-07-12}}</ref>
 
===The Simple project===
The goal of Simple is to bring an easy to learn and use language to the Android platform.<ref>{{cite web |url = http://code.google.com/p/simple/ |title = Android Simple}}</ref> Simple is a [[BASIC]] dialect for developing Android applications. It targets professional and non-professional programmers alike in that it allows programmers to quickly write Android applications that utilise the Android runtime components.