Mobile computing allows transmission of data without a fixed connection. It uses technologies like cellular networks and sensors in smartphones. The major mobile operating systems are Android and iOS. Android is an open source operating system based on Linux. It uses Java and other languages for development. Key components of Android apps include activities, services, content providers, intents, broadcast receivers, and notifications. Activities provide the user interface, services run in the background, and other components enable data sharing and responding to events.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
106 views
Mobile Programming: Engr. Waqar Ahmed
Mobile computing allows transmission of data without a fixed connection. It uses technologies like cellular networks and sensors in smartphones. The major mobile operating systems are Android and iOS. Android is an open source operating system based on Linux. It uses Java and other languages for development. Key components of Android apps include activities, services, content providers, intents, broadcast receivers, and notifications. Activities provide the user interface, services run in the background, and other components enable data sharing and responding to events.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 22
Mobile Programming
Engr. Waqar Ahmed
MUET, Shaheed Z.A Bhutto Campus Khairpur Mir’s
Introducing Mobile Computing • A technology that allows transmission of data, via a computer, without having to be connected to a fixed physical link .
• Mobile data communication is rapidly evolving
technology as it allows users to transmit data from remote locations to other remote or fixed locations. Applications of Mobile Computing • Emergency services • CDPD (Cellular Digital Packet Data) • Credit card Verification • Estate agents • Location services • Traffic information • Entertainment, etc Mobile Operating Systems An operating system that operates a smartphone, tablet, PDA, or other mobile device. Android Android is a mobile operating system developed by Google, based on the Linux kernel and designed primarily for touchscreen mobile devices such as smart phones and tablets. • The current Android version is 8.0 Oreo. • The releases are nicknamed like Ginger Bread (2.3), Honeycomb (3.0), Ice Cream Sandwich (4.0), Jelly Bean (4.1) and Kit Kat (4.4). Android API Level iOS • iOS is from Apple Inc. It is closed source and built on open source Darwin core OS. • The Apple iPhone, iPod Touch, iPad and second-generatio n Apple TV all use this operating system derived from Mac OS X. Sensors in a smart phones Sensors growth in smartphones Introduction to Android • Open software platform for mobile development • A complete stack – OS, Middleware, Applications • An Open Handset Alliance (OHA) project • Powered by Linux operating system • Open source under the Apache 2 license Development languages for Android • Java • Kotlin • C/C++ • C# • BASIC • Corona • PhoneGap
For further Studies
https://www.androidauthority.com/develop-android-apps-languages-learn-391008/ Android framework HAL Basics of Android Application • In Android, mostly the applications are programmed in Java.
Following are the types of Android applications
Foreground Activity • An application that’s only useful when it’s in the foreground and is effectively suspended when it’s not visible. • Games and map mashups are common examples. Basics of Android Application Background Service • An application with limited interaction that spends most of its lifetime hidden. Examples of this include call screening applications or SMS auto-responders. Intermittent Activity • Expects some interactivity but does most of its work in the background. • Often these applications will be set up and then run silently, notifying users when appropriate. • A common example would be a media player. Components of Android Application • There are six components that provide the building blocks for Android applications: 1. Activities 2. Services 3. Content Providers 4. Intents 5. Broadcast Receivers 6. Notifications Activities • Its is the application’s presentation layer. • Every screen in the application will be an extension of the Activity class. • Activities use Views to form graphical user interfaces that display information and respond to user actions. • But, they can: – Be faceless – Be in a floating window – Return a value Services • The invisible workers of the application.
• Service components run invisibly, updating the data sources and
visible Activities and triggering Notifications.
• They’re used to perform regular processing that needs to continue
even when your application’s Activities aren’t active or visible. E.g. music player, network download etc… Content Providers • A shareable data store.
• Content Providers are used to manage and share application databases
• They are the preferred way of sharing data across application
boundaries. This means that you can configure your own Content Providers to permit access from other applications • Enables sharing of data across applications – E.g. address book, photo gallery Intents • Think of Intents as a verb and object; a description of what you want d one – E.g. VIEW, CALL, PLAY etc.. • System matches Intent with Activity that can best provide the service • Using Intents, you can broadcast messages system-wide or to a target Activity or Service, stating your intention to have an action performed • The system will then determine the target(s) that will perform any acti ons as appropriate. Broadcast Receivers
• They are Intent broadcast consumers.
• By creating and registering a Broadcast receiver, your application can listen for broadcast Intents that match specific filter criteria. • Broadcast Receivers will automatically start your application to respond to an incoming Intent, making them ideal for event-driven applications. Notification • A user notification framework. • Notifications let you signal users without stealing focus or interrupting their current Activities. • They are the preferred technique for getting a user’s attention from within a Service or Broadcast Receiver.