15. Android applications are compiled to Dalvik byte code Write app in Java Compiled in Java Transformed to Dalvik byte code Linux OS Loaded into Dalvik VM
16. Android SDK ADT: Android Development Tool, an Eclipe plugin Two debuggers adb : Android Debug Bridge ddms : Dalvik Debug Monitor Server aapk : Android Application package tool All resources are bundled into an archive, called apk file. dx : java byte code to Dalvik executable translator
17. Differences between Smart Phones Feature Android Windows mobile BlackBerry company Google Microsoft RIM OS family Linux Windows Mobile OS Languages Java Visual C++ C++ SDK Platform Multiplatform dependent dependent Face book Yes Yes Yes Multitasking Yes limited limited
18. Differences between Apple and Android Specification Apple Android Ownership Apple Proprietary Google open Source Compatible Access Technology 3G,3.5G,Wi-Fi,Bluetooth 2G,3G,3.5G and 4G(GSM , CDMA,Bluetooth,Wi-Fi, and WiMAX) Compatible Devices iPod , iPod Touch, iPhones Any Devices Messaging SMS , MMS ,email SMS , MMS , email and C2DM Web Browser Safari Open source Web kit layout engine coupled with Chrome’s V8 JavaScript engine Connectivity Wi-Fi, Bluetooth Wi-Fi, Bluetooth and NFC Multitasking Supported Supported Other device connectivity (Internet) Bluetooth (Internet Tethering) Hotspot feature with Wi-Fi
19. Differences between Apple and Android Specification Apple Android Chrome to phone Not supported Supported 3D Google Map Not Yet Supported Email Attachments Single file only Multiple files Google Talk Web browser chat GTalk Specific Client and Video Supported Hardware Vendors Apple Samsung,Motorola,LG,Sony Ericsson, Dell,Huawei,HTC 3rd Party Branded OS No Supported Adobe Flash Support Not Supported Supported
20. Android applications have common structure Views such as lists, grids, text boxes, buttons, and even an embeddable web browser Content Providers that enable applications to access data from other applications (such as Contacts), or to share their own data A Resource Manager , providing access to non-code resources such as localized strings, graphics, and layout files A Notification Manager that enables all apps to display custom alerts in the status bar An Activity Manager that manages the life cycle of applications and provides a common navigation backstack
21. Android applications have common structure Broadcast receivers can trigger intents that start an application Data storage provide data for your apps, and can be shared between apps – database, file, and shared preferences (hash map) used by group of applications Services run in the background and have no UI for the user – they will update data, and trigger events Intents specify what specific action should be performed Activity is the presentation layer of your app: there will be one per screen, and the Views provide the UI to the activity
22. Replacing & Reusing Components GMail Contacts Home Blogger Chat Client component makes a request for a specific action “ Pick photo” Picasa System picks best component for that action New components can use existing functionality Blogger Photo Gallery
23. There is a common file structure for applications code images files UI layouts constants Autogenerated resource list
24.
25. Project Properties Project Name This is the name of the directory or folder on your computer that you want to contain the project. Package Name This is the package namespace (following the same rules as for packages in the Java programming language) that you want all your source code to reside under. This also sets the package name under which the stub Activity will be generated. The package name you use in your application must be unique across all packages installed on the system; for this reason, it's very important to use a standard domain-style package for your applications. In the example above, we used the package domain "com.chicagoandroids". Activity Name This is the name for the class stub that will be generated by the plug-in. This will be a subclass of Android's Activity class. An Activity is simply a class that can run and do work. It can create a UI if it chooses, but it doesn't need to. Application Name This is the human-readable title for your application.