0% found this document useful (0 votes)
6 views

Chapter 2 Mobile Application Development

The document provides an overview of mobile application development, focusing on Android as an open-source operating system for mobile devices. It discusses the features of Android, its architecture, and the role of the Open Handset Alliance in its development, as well as the user interface design principles for Android applications. Additionally, it compares Android with iOS and Windows Phone architectures, highlighting their unique features and design considerations.

Uploaded by

ajebaderesa12
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Chapter 2 Mobile Application Development

The document provides an overview of mobile application development, focusing on Android as an open-source operating system for mobile devices. It discusses the features of Android, its architecture, and the role of the Open Handset Alliance in its development, as well as the user interface design principles for Android applications. Additionally, it compares Android with iOS and Windows Phone architectures, highlighting their unique features and design considerations.

Uploaded by

ajebaderesa12
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 53

CHAPTER :2

Introduction to
Mobile Application Development
Compiled By:
Kasaye A.
What is Android?
Android is an open source and Linux-based Operating System for mobile devices such as
smartphones and tablet computers. Android was developed by the Open Handset Alliance, led by
Google, and other companies.

Android offers a unified approach to application development for mobile devices which means
developers need only develop for Android, and their applications should be able to run on different
devices powered by Android.

The first beta version of the Android Software Development Kit (SDK) was released by Google in
2007 where as the first commercial version, Android 1.0, was released in September 2008.

On June 27, 2012, at the Google I/O conference, Google announced the next Android version, 4.1
Jelly Bean. Jelly Bean is an incremental update, with the primary aim of improving the user interface,
both in terms of functionality and performance.

The source code for Android is available under free and open source software licenses. Google
publishes most of the code under the Apache License version 2.0 and the rest, Linux kernel changes,
under the GNU General Public License version 2.
Why Android ?
Features of Android
 Beautiful UI: Android OS basic screen provides a beautiful and
intuitive user interface.
 Connectivity: GSM/EDGE, IDEN, CDMA, EV-DO, UMTS,
Bluetooth, Wi-Fi, LTE, NFC and WiMAX.
 Storage: SQLite, a lightweight relational database, is used for data
storage purposes.
 Media Support:H.263, H.264, MPEG-4 SP, AMR, AMR-WB,
AAC, HE-AAC, AAC 5.1, MP3, MIDI, Ogg Vorbis, WAV, JPEG,
PNG, GIF, and BMP.
 Messaging: SMS and MMS[Multimedia Message Service]
 Web browser: Based on the open-source WebKit layout engine,
coupled with Chrome's V8 JavaScript engine supporting HTML5
and CSS3.
 Multi-touch: Android has native support for multi-touch which
was initially made available in handsets such as the HTC Hero.
Features of Android…
 Multi-tasking: User can jump from one task to another and
same time various application can run simultaneously.
 Resizable widgets: Widgets are resizable, so users can
expand them to show more content or shrink them to save
space.
 Multi-Language: Supports single direction and bi-
directional text.
 GCM: Google Cloud Messaging (GCM) is a service that lets
developers send short message data to their users on Android
devices, without needing a proprietary sync solution.
 Wi-Fi Direct: A technology that lets apps discover and pair
directly, over a high-bandwidth peer-to-peer connection.
 Android Beam: A popular NFC-based technology that lets
users instantly share, just by touching two NFC-enabled
phones together.
Open Handset Alliance (OHA)
 The Open Handset Alliance (OHA) is a association of 84 firms [organizations] to develop
open standards for mobile devices. Member firms include Google, HTC, Sony, Dell, Intel,
Motorola, Qualcomm, Texas Instruments, Samsung Electronics, LG Electronics, T-Mobile,
Sprint Corporation, Nvidia, and Wind River Systems
 Linux version 2.6.x for core system services.
 Provides proven driver model.
 Provides: memorymanagement, process
management, security model, networking and lot of
core OS infrastructure
 Libc:c standard library
 SSL: Secure Socket Layer

 Surface Manager:
responsible for
composing different
drawing surfaces onto the
screen.
 OpenGL|ES : 3D Image Engine
 SGL : 2D image Engine.
 Hence we can combine 3D and 2D graphics in the same application.
 Media Framework : Core part of the android multimedia.
MPEG4,H264,MP3,AAC…..

 FreeType: To render the fonts.


 WebKit:open source browser engine. Helps to work well on small
screen.
 SQLite: Embedded Database for storing data
•Android runtime meet the needs of running in an embedded environment ,i.e.,
where is limited battery, limited Memory and limited CPU.

• CORE LIBRARIES:
Java Programming Language
 contains all the collection classes, utilities, IO..all these utilities which you come
across and expected to use.

•DALVIK VIRTUAL MACHINE:


Java based license free VM
Optimization for low memory requirements.
DVM runs .dex files (byte codes) that converts during built time.

 more efficient and run very well on


small processors.
structure are designed to be shared
across processes due to which multiple
instance of DVM running on device at
the same time one in several processes
 Activity Manager – Controls all aspects of the application lifecycle and activity
stack.
 Content Providers – Allows applications to publish and share data with other
applications.
 Resource Manager – Provides access to non-code embedded resources such as
strings, color settings and user interface layouts.
 Notifications Manager – Allows applications to display alerts and notifications to
the user.
 View System – An extensible set of views used to create application user interfaces.
 Package Manager – The system by which applications are able to find out
information about other applications currently installed on the device.
 Telephony Manager – Provides information to the application about the telephony
services available on the device such as status and subscriber information.
 Location Manager – Provides access to the location services allowing an
application to receive updates about location changes.
Located at the top of the Android software stack are the
applications. These comprise both the native applications
provided with the particular Android implementation (for
example web browser and email applications) and the third
party applications installed by the user after purchasing the
device.
The iPhone operating system[iOS Architecture]
Similar to basic architecture found in Mac OS X

 Acts intermediate between applications and hardware

iO
Apps S
Hardware
The Layers in iOS Architecture Technology

 Consists of four Abstraction layers


• Core OS Layer

• Core service Layer

• The Media Layer

• The Cocoa Touch Layer

Uses Darwin foundation and therefore a unix like OS

 The user interface of iOS is based on the concept of direct


manipulation, using multi-touch gestures.
The core of iOS

Contains the low-level features such as


Accelerate Framework (Accelerate.framework)
This framework contains interfaces for performing DSP, linear
algebra, and image-processing calculations
Core Bluetooth (CoreBluetooth.framework)
This framework allows developers to interact specifically with
Bluetooth Low-Energy ("LE") accessories

External Accessory Framework (ExternalAccessory.framework)


This framework provides support for communicating with
hardware accessories attached to an iOS based device
Core services Layer

Contains the High-level features that all applications use such as

iCloud Storage
lets your application write data to a central location and access those
items from all user’s computers and iOS devices
Core services framework
Includes Accounts.framework, AddressBook.framework and
CoreData.framework for user accounts ,contacts and for managing
model-view-controller application

iCloud
Media Layer

The Media layer contains the graphics, audio, and video technologies
Graphics Technologies

Includes Core Graphics , Core Animation and OpenGL technologies which


handles 2D vector and animating views and 2D and 3D figures
Audio Technologies

Supports rich audio experince and audio formats like AAC, Apple
Lossless(ALAC),A-Law and Linear PCM

Video technologies

The iOS support the playback of movie files with the .mov, .mp4, .m4v,
and .3gp filename extensions
Compression standards in Video Technologies

● H.264 video, up to 1.5 Mbps, 640x480 pixels, 30 frames


per second

• H.264 video, up to 768 Kbps, 320x240 pixels, 30 frames per


second

• MPEG-4 video, up to 2.5 Mbps, 640x480 pixels, 30 frames per


second

Media layer also consists of different frameworks like


CoreAudio.framework, CoreImage.framework and
CoreText.framework
Cocoa Touch Layer

The Cocoa Touch layer contains the key frameworks for building iOS
applications

The layer defines the basic application and


support for key technologies such as
multitasking, touch-based input,push
notifications, and many high-level system
services

Cocoa Touch follows a Model-View-


Controller (MVC) software architecture
Architecture and working of Windows phone 8 OS
 Windows Phone 8 is the second generation of the Windows Phone mobile operating system from
Microsoft. It was released on October 29, 2012, and like its predecessor, it features a flat user
interface based on Metro design language. It was succeeded by Windows Phone 8.1, which was
unveiled on April 2, 2014.
 Windows phone follows the layered architecture as shown in the figure below. Compared with
iphone os WP runs on a variety of devices.WP-8 includes Multi-core support. Minimum Hardware
specification include ARM7 CPU, a DirectX capable GPU, a camera, a multi-touch capacitive
camera.
 Most of the windows phone 8 apps are built as managed aaps using XAML with C# or VB.Net. It is
also possible to render 3D graphics within a XAML warper.
CHAPTER THREE

User interface Design


UI Design for mobile Applications
 “User Interface Design” or UI design describes the design of

websites, apps and other graphical elements of software


applications, as well as everyday objects that interface with a screen.

 User interface design patterns are good solutions to standard user

interface design problems. The UI designs are generally identified


and articulated by design experts. UI design patterns or universal
solutions that likely work across wide range of applications and on
different platforms, although some patterns are platform specific.
Introduction
 Android is a widely used OS made for smart phones and tablets. It is an

open source project led by Google and it is released under Apache


License.

 This permissive license helped this OS to be widely adopted and allows

the manufacturers to freely modify and customize it.

 All android applications, called apps, are built on Android UI

framework. App interface is the first thing a user sees and interacts with.

 From the user perspective, this framework keeps the overall experience

consistent for every app installed in our Smartphone or tablets.


Introduction….
 From the developer perspective, this framework provides some basic

blocks that can be used to build complex and consistent user interface
(API).

 Android UI interface is divided in three different areas:


 Home screen

 All apps

 Recent screen

 The home screen is the “landing” area when we power our phone on. This

interface is highly customizable and themed. Using widgets we can create and
personalize our “home” screen. All apps is the interface where the app installed
are displayed, while recent screens are the list of last used apps.
Android App Structure and UI patterns
 Android apps are very different from each other because
they try to address different user needs.
 There are simple apps with a very simple UI that has just
only one view and there are other apps much more
complex with a very structured navigation and multiple
views.
 In general, we can say an Android app is made by a top-
level view and detail/level view. Slide no-4
 One of the biggest efforts made by Google was to define
a well defined set of rules that helps developers to create
appealing user interfaces. At the same time, these rules
help users to navigate through every app in the same way.
We call this UI consistency.
Android App Structure and UI patterns…
 Android, moreover, guarantees to the developers the
required flexibility to customize the app look and feel and
make it unique.
 These rules are known as UI patterns. Patterns are proven
solution approaches to well known problems. Thus, having a
well defined UI pattern catalog and knowing when and
where apply them, we can create appealing apps that are not
only full of interesting features but they are enjoyable by
users and easy to use.
Top level view
 The top level view is the “landing” area of our app, This is the first thing
an user sees of our app. There are some specific patterns that can be
applied when designing this view depending on the type of information
we want to show:
 Fixed tabs

 Spinner

 Navigation drawer

 We can use

1. fixed tabs when we want to give to the user an overview of the different
views present in our app, so that a user can switch easily between them to
show different type of information. A typical example is a app that shows
tech news: in this case we could use different tabs to group news like
(‘Android’, iOS, ‘Games’ and so on).
2. Spinner is used when we want to move directly to a specific view,
this is the case of a calendar app when we can use spinner to go
directly to a specific month.
3.The navigation drawer is one of the newest patterns introduced by
Google. This is a sliding menu, usually at the left side of the
Smartphone screen, that can be opened and closed by the user.
 Detail view : The detail view is a low level view where a user can
interact with data directly. It is used to show data and edit them.
 Action Bar : An action bar is a piece of the screen, usually at the
top, that is persistent across multiple views. It provides some key
functions:
 App branding: icon area
 Title area
 Key action area
 Menu area
Standard Components
 How do we build a user interface? Android gives some key

components that can be used to create user interface that follows


the pattern we talked about before. All the Android user interface
are built using these key components:

 View: It is the base class for all visual components (control and

widgets). All the controls present in an android app are derived


from this class. A View is an object that draws something on a
Smartphone screen and enables an user to interact with it.

 View group: A View Group can contain one or more Views and

defines how these Views are placed in the user interface (these are
used along with Android Layout managers.
Standard Components…
 we can extend them and create a custom control with a custom layout and
behavior. Using these four components and following the standard UI patterns
we can create amazing apps that are “easy-to-use
 Android provides some standard UI components that can be grouped in:
 Tabs
 Spinners
 Pickers
 Lists
 Buttons
 Dialogs
 Grid lists
 TextFields
 If we analyze in more detail an Android user interface has an hierarchical
structure where at the root there’s a ViewGroup. A ViewGroup behaves like an
invisible container where single views are placed following some rules. We can
combine ViewGroup with ViewGroup to have more control on how views are
located.
 If we create a simple android app, using our IDE, we can verify the
UI structure

From the example above, we can notice that at the top of the hierarchy there is a
ViewGroup (called Relative Layout) and then there are a list of view child (controls and
widgets).
When we want to create an UI in Android we have to create some files in XML format.
Android is very powerful from this point of view because we can “describe” our UI interface
just in XML format. The OS will then convert it in a real code lines when we compile our
app and create the apk.
Managing Application data
 Application data comes from various sources, such as user-
generated inputs, operating system data, data received from the
Web, and application-produced data. Some of the application data
is transient, and you don’t need to save it in persistent storage,
such as a Secure Digital (SD) card or device memory, or to save it
on the Web; but other data may need to be persisted either in local
data storage or to the Web so
 Generally, you have control over a few data storage design
decisions when creating a mobile application:
 Where to save the data
 What format to save the data in
 How data is shared between applications
Managing Application data…
 Historically, mobile applications on major software
platforms usually have saved data locally on the
device. For example, on Windows Mobile devices an
application can use the registry to save some
application-specific settings and use file system APIs
to save other data to either the application can access
it later.
 Device memory or an SD card. The iPhone Operating
System (iOS) and Android both provide APIs to save
data locally and privately — only the application can
access its data
Local and Cloud
 Mobile applications commonly combine local and cloud data as part of the data

usage model. Sometimes this is the only viable approach, because the cloud
data, such as RSS feeds, isn’t under the developer’s control. When an
application is running, it can store its data completely in memory when the data
size isn’t too large. If the data becomes too large to store in memory, the
application relies on persistent storage on the device.

 In both cases, the application can communicate with cloud storage or a web
service provider to download the latest data, as well as upload updates to the
cloud or web service. Communication of this sort generally requires a
synchronization framework that developers can use to build both the device-
side and cloud-side applications to ensure data consistency without worrying
about a data connection and synchronization management.
Local and Cloud…
 Android provides a synchronization service and a
SyncAdapter class that developers can use to build data
synchronization with cloud storage (the server). By
extending the AbstractThreadedSyncAdapter class and
implementing the onPerformSync(Account, Bundle, String,
ContentProviderClient, SyncResult) method, the system’s
sync service can perform the specifi ed data sync operations
 Local Files and Databases
Local Files and Databases
 When an application has smaller data requirements (usually in the form of key-
value pairs), all it really needs is a custom file or an XML file to save them. The
application simply implements data serialization and de-serialization to and from
the file.
 Android provides standard Java file system methods such as FileOutputStream()
and FileInputStream() to access the application’s private storage. Developers can
use the android.utils.Xml class or Simple API for XML (SAX) in the org.xml.sax
namespace and the javax. xml.parsers namespace to parse XML fi les.
 In addition to using custom files or XML files, using a SQL database engine is a
natural choice for applications that employ a complex data model. The advantages
of using a SQL database to store and access data are:
 A database manages structured data and enables flexible access.
 A database maintains consistent data with schemes and transactions.
 Applications can leverage easy-to-use SQL commands to query and update
data.
 A database provides good query and update performance.
 A database provides enhanced data security.
Integrating Cloud Services
 cloud computing means many things. for mobile app developers, it provides the ability
to build aap that the millions of people can use. Cloud computing makes it easier to
handle large and growing number of users . A mobile cloud application is a software
program that is designed to be accessed over the internet by many types of portable
computing devices.

 Cloud-based integration is a form of systems integration business delivered as a


cloud computing service that addresses data, process, service-oriented architecture
(SOA) and application integration.
 MCC uses computational augmentation approaches (computations are executed
remotely instead of on the device) by which resource-constraint mobile devices can
utilize computational resources of varied cloud-based resources.
SaaS (Software as a Service)
 SaaS or software as a service is a software distribution model in which applications
are hosted by a vendor or service provider and made available to customers over a
network (internet). SaaS is becoming an increasingly prevalent delivery model as
underlying technologies that supports Service Oriented Architecture (SOA) or
Web Services.Through internet this service is available to users anywhere in the world.

Traditionally, software application needed to be purchased upfront &then installed it onto your computer.
SaaS users on the other hand, instead of purchasing the software subscribes to it, usually on monthly basis
via internet.
Anyone who needs an access to a particular piece of software can be subscribe as a user, whether it is one
or two people or every thousands of employees in a corporation. SaaS is compatible with all internet
enabled devices
PaaS (Platform as a Service)
 Platform as a service, is referred as PaaS, it provides a platform and environment to allow developers to build
applications and services.This service is hosted in the cloud and accessed by the users via internet.
 To understand in a simple terms, let compare this with painting a picture, where you are provided with paint
colors, different paint brushes and paper by your school teacher and you just have to draw a beautiful picture
using those tools.

PaaS services are constantly updated & new features added. Software developers, web
developers and business can benefit from PaaS. It provides platform to support
application development. It includes software support and management services,
storage, networking, deploying, testing, collaborating, hosting and maintaining
applications.
IaaS (Infrastructure as a Service)
 IaaS (Infrastructure As A Service) is one of the fundamental service model of cloud
computing alongside PaaS( Platform as a Service). It provides access to computing
resources in a virtualized environment “the cloud” on internet. It provides computing
infrastructure like virtual server space, network connections, bandwidth, load balancers
and IP addresses. The pool of hardware resource is extracted from multiple servers and
networks usually distributed across numerous data centers. This provides redundancy and
reliability to IaaS.

IaaS(Infrastructure as a service) is a complete package for computing. For small scale


businesses who are looking for cutting cost on IT infrastructure, IaaS is one of the solutions.
Annually a lot of money is spent in maintenance and buying new components like hard-
drives, network connections, external storage device etc. which a business owner could have
saved for other expenses by using IaaS
Advantages of Integrating Mobile Cloud Services
 Up-to-date Information: As all the applications on the cloud
are in-sync with each other, the end-users are able to fetch the most
recent data or information related to various activities. A change
made by one user reflects on another application almost
instantaneously.
 Improved functioning: Changing all the manual segments to
automated ones improves the accuracy level of various operations.
This facilitates in a frictionless system-to-system process
automation and eventually improves the overall efficiency of
information sharing.
 Streamline business goals: Integration of businesses on cloud,
lines up the various aspects of a business like procurement or
ecommerce management, logistics etc. A clear projection of the
various entities can be drawn in the perspective of workforce.
Advantages of Integrating Mobile Cloud Services…

 Safe: A user-name and password is allocated to each and every


employee in order to verify themselves to gain access to cloud. A set of
security protocols are also followed so that the information cannot be
modified or altered by someone who doesn’t have the access to do so.
 Flexibility and Scalability: Enterprise applications’ and
infrastructure’s integration with the cloud facilitates a simple solution
for organizations to upgrade or downgrade their business
requirements. This helps businesses to maintain the cost of various
operations related to different projects or tasks.
 Higher availability: Cloud computing integration provides higher
availability of different resources to the end users. As all the services
are hosted on a cloud, it improves the efficiency of the organization’s
infrastructure. Since only an internet connection is needed to access
this cloud, there is no limitation on boundaries or on-premises
mobility.
Integrating Networking
 The fundamental purpose of a mobile device is to liberate users
from restrictions of place. Therefore, it is only natural that the
connection to a fixed network is gaining more and more interest
in the domain of applications, and the role of a mobile device as
an execution environment for local applications only is becoming
less attractive.
 Furthermore, assuming that it is the contents and data that users
are consuming, it is obvious that they should be loaded over the
network in some form or another, as communication is the main
purpose of many mobile devices.
 Basic Connectivity

You might also like