| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 1 | page.title=Overview |
| 2 | @jd:body |
| 3 | |
| 4 | <p>Developing applications for Android devices is facilitated by a group of tools that are |
| 5 | provided with the SDK. You can access these tools through an Eclipse plugin called ADT (Android |
| 6 | Development Tools) or from the command line. Developing with Eclipse is the preferred method because |
| 7 | it can directly invoke the tools that you need while developing applications.</p> |
| 8 | |
| 9 | <p>However, you may choose to develop with another IDE or a simple text editor and invoke the |
| 10 | tools on the command line or with scripts. This is a less streamlined way to develop because you |
| 11 | will sometimes have to call command line tools manually, but you will have access to the same |
| 12 | amount of features that you would have in Eclipse.</p> |
| 13 | |
| 14 | <p>The basic steps for developing applications with or without Eclipse are the same:</p> |
| 15 | |
| 16 | <ol> |
| 17 | <li>Install Eclipse or your own IDE. |
| 18 | |
| 19 | <p>Install Eclipse along with <a href="{@docRoot}sdk/eclipse-adt.html#installing">the ADT |
| 20 | Plugin</a>, or install an editor of your choice if you want to use the command line SDK tools. |
| 21 | If you are already developing applications, be sure to <a href= |
| 22 | "{@docRoot}sdk/eclipse-adt.html#updating">update Your ADT Plugin</a> to the latest version |
| 23 | before continuing.</p> |
| 24 | </li> |
| 25 | |
| Robert Ly | c74a69a8 | 2011-01-04 22:48:02 -0800 | [diff] [blame] | 26 | <li>Set up Android Virtual Devices or hardware devices</a>. |
| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 27 | |
| 28 | <p>You need to create Android Virtual Devices (AVD) or connect hardware devices on which |
| 29 | you will install your applications.</p> |
| Robert Ly | c74a69a8 | 2011-01-04 22:48:02 -0800 | [diff] [blame] | 30 | |
| 31 | <p>See <a href="{@docRoot}guide/developing/devices/index.html">Creating and Managing Virtual Devices</a> |
| 32 | and <a href="{@docRoot}guide/developing/device.html">Connecting Hardware Devices</a> for more information. |
| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 33 | </li> |
| 34 | |
| 35 | <li> |
| Robert Ly | c74a69a8 | 2011-01-04 22:48:02 -0800 | [diff] [blame] | 36 | <a href="{@docRoot}guide/developing/projects/index.html">Create an Android project</a>. |
| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 37 | |
| 38 | <p>An Android project contains all source code and resource files for your application. It is |
| 39 | built into an <code>.apk</code> package that you can install on Android devices.</p> |
| 40 | </li> |
| 41 | |
| 42 | <li> |
| Robert Ly | c74a69a8 | 2011-01-04 22:48:02 -0800 | [diff] [blame] | 43 | <a href="{@docRoot}guide/developing/building/index.html">Build and run your |
| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 44 | application</a>. |
| 45 | |
| 46 | <p>If you are using Eclipse, builds are generated each time you save changes and you can install |
| 47 | your application on a device by clicking <strong>Run</strong>. If you're using another IDE, you can build your |
| Robert Ly | c74a69a8 | 2011-01-04 22:48:02 -0800 | [diff] [blame] | 48 | project using Ant and install it on a device using <code>adb</code>.</p> |
| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 49 | </li> |
| 50 | |
| 51 | <li> |
| Robert Ly | c74a69a8 | 2011-01-04 22:48:02 -0800 | [diff] [blame] | 52 | <a href="{@docRoot}guide/developing/debugging/index.html">Debug your application with the |
| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 53 | SDK debugging and logging tools</a>. |
| 54 | |
| 55 | <p>Debugging your application involves using a JDWP-compliant debugger along with the |
| 56 | debugging and logging tools that are provided with the Android SDK. Eclipse already |
| 57 | comes packaged with a compatible debugger.</p> |
| 58 | </li> |
| 59 | |
| 60 | <li> |
| 61 | <a href="{@docRoot}guide/developing/testing/index.html">Test your application with the |
| 62 | Testing and Instrumentation framework</a>. |
| 63 | |
| 64 | <p>The Android SDK provides a testing and instrumnetation framework to help you set up and |
| 65 | run tests within an emulator or device.</p> |
| 66 | </li> |
| 67 | </ol> |
| 68 | |
| 69 | <h2 id="EssentialTools">Essential command line tools</h2> |
| 70 | |
| 71 | <p>When developing in IDEs or editors other than Eclipse, be familiar with |
| 72 | all of the tools below, because you will have to run them from the command line.</p> |
| 73 | |
| 74 | <dl> |
| 75 | <dt><a href="{@docRoot}guide/developing/tools/android.html">android</a></dt> |
| 76 | |
| 77 | <dd>Create and update Android projects and create, move, and delete AVDs.</dd> |
| 78 | |
| 79 | <dt><a href="{@docRoot}guide/developing/devices/emulator.html">Android Emulator</a></dt> |
| 80 | |
| 81 | <dd>Run your Android applications on an emulated Android platform.</dd> |
| 82 | |
| 83 | <dt><a href="{@docRoot}guide/developing/tools/adb.html">Android Debug Bridge</a></dt> |
| 84 | |
| 85 | <dd>Interface with your emulator or connected device (install apps, shell the device, issue |
| 86 | commands, etc.).</dd> |
| 87 | </dl> |
| 88 | |
| 89 | <p>In addition to the above tools that are included with the SDK, you need the following open |
| 90 | source and third-party tools:</p> |
| 91 | |
| 92 | <dl> |
| 93 | <dt>Ant</dt> |
| 94 | |
| 95 | <dd>To compile and build your Android project into an installable .apk file.</dd> |
| 96 | |
| 97 | <dt>Keytool</dt> |
| 98 | |
| 99 | <dd>To generate a keystore and private key, used to sign your .apk file. Keytool is part of the |
| 100 | JDK.</dd> |
| 101 | |
| 102 | <dt>Jarsigner (or similar signing tool)</dt> |
| 103 | |
| 104 | <dd>To sign your .apk file with a private key generated by keytool. Jarsigner is part of the |
| 105 | JDK.</dd> |
| 106 | </dl> |
| 107 | |
| 108 | <p>If you are using Eclipse and ADT, tools such as <code>adb</code> and the <code>android</code> |
| 109 | are called by Eclipse and ADT under the hood or similar functionality is provided within Eclipse. |
| 110 | You need to be familiar with <code>adb</code>, however, because certain functions are not accessible from |
| 111 | Eclipse, such as the <code>adb</code> shell commands. You might also need to call Keytool and Jarsigner to |
| 112 | sign your applications, but you can set up Eclipse to do this automatically as well.</p> |
| 113 | |
| Robert Ly | c74a69a8 | 2011-01-04 22:48:02 -0800 | [diff] [blame] | 114 | <p>For more information on the tools provided with the Android SDK, see the |
| 115 | <a href="{@docRoot}guide/developing/tools/index.html">Tools</a> section of the documentation.</p> |
| Robert Ly | ee2dacd1 | 2010-12-22 09:46:12 -0800 | [diff] [blame] | 116 | |