Post on 21-Oct-2014
description
transcript
Designing Mobile Applications
Anand NaikDevelopment Manager, Cross Country Infotechsolutions@crosscountry.com
Slide 2
AbstractThis document discusses the architecture of typical mobile applications. It also provides a comparison between Web and mobile applications. Designers and Architects can benefit from the design guidelines presented in this document. The document does not discuss nontechnical issues, such as issues related to resources or development methodologies, which are faced during the development of mobile applications.
Slide 3
Introduction• The development of mobile applications is not new. The concept is at least a decade
old. However, in the recent past, it has grown at an enormous speed. • The upsurge of smart phones and mobile operating systems are some of the factors
that drive this growth. In addition, the developer community is encouraged to see direct access to customers through various channels such as AppStore, marketplace, and other channels.
• The software industry has matured to a great extent, but the area of mobile application development still opens up loads of issues.
• Herds of Web application developers are jumping into mobile application development with the baggage of their Web development experience.
Slide 4
What Are Mobile Applications?• Any software application that uses a mobile phone as a platform to execute specific
tasks is called a mobile application.
• Mobile applications can be native applications that are written by using device-based software tools.
• They could be browser-based applications that use HTML, JavaScript, or cascading style sheets or they could be SMS-based applications.
• Mobile applications differ from Web-based applications in various aspects, a development team needs to consider these differences while making design decisions.
• The addition of mobility requires considering various factors, which include network connectivity, device capabilities, power supply, wide range of user interfaces, and numerous platforms.
Slide 5
Mobile Application Architecture and DesignMobile User
UI Components Event Handlers
Business Layer Controller
Native Controller
Business Orchestration
Service Adapters
Native Adapter
Native API
Data Access Controller
Data AccessAdapter
Native OS Local Data Storage/Cache
Presentation
Business
Local Services
Mobile Ecosystem
Services Deployed on Application Server
Layers
Slide 6
Presentation Layer (Contd...)
• The presentation layer primarily has two main components—the UI components and the event handlers.
• The UI components are visible to the mobile user, for example, a text box. • The UI components generate events when acted upon by the user. • These events are caught by the event handlers for further processing. The design of the
presentation layer is important for a rich user experience.
Web Application Mobile Application
Fixed layout orientation Portrait or landscape layouts
Fixed set of resolutions/screen sizes Variety of resolutions and screen sizes
No local caching Local caching
Enough real estate available Limited amount of real estate
Standard input methods New & cumbersome input methods
Consistent network availability with enough bandwidth Inconsistent network availability with limited bandwidth
SSL and encryption support Some old devices may have issues
Continuous power supply Uses battery power
Slide 7
Presentation Layer Design Guidelines
If your application needs to be portable across devices, it should use platform-independent technologies such as Titanium and PhoneGap.
Design your application to fit the portrait and the landscape layout.
The real estate available on the mobile has a direct relation with user experience. Design your applications to use this scarce resource. Decide the target resolutions and operating systems and fit the layout accordingly.
Use consistent and simple navigation. Do not make it overly complex.
Use local caching as a mechanism to improve user experience. Do not cache sensitive data in unencrypted format. Do not rely on the cached data to a great extent.
Use exceptions carefully. Differentiate between exceptions and take appropriate actions.
The mobile keyboard is not as easy to operate as a desktop keyboard. Your UI design should allow users to enter minimum amount of data.
Consider designing for touch screen and stylus-enabled devices.
Keep the rendering logic separate from the business logic.
Validate the input and handle validation errors correctly.
Avoid using references to external resources such as images because it makes a network call and thereby consumes network bandwidth.
Because complete URLs are not usually visible, it makes a phisher’s life easy. The application should attempt to use small URLs that are completely visible.
On screen keyboard used for input reduces the real estate available, limiting the visibility of the screen. UI design should take care of this.
Navigation varies depending on the device for example iPhone has only one physical button for navigation while in android, back button and context menu makes it easier to navigate.
Avoid using heavy media files to conserve battery power.
Slide 8
Business Layer (Contd..)
• The business layer contains the Business Layer Controller, Business Layer Orchestration, Native Controller, and the Service Adapter.
• The Business Layer Controller provides an interface to the presentation layer to interact with the business logic.
• The Business Layer Orchestration carries out various business operations, such as getting information from the mobile ecosystem through the Native Controller, getting local data through the Data Access Controller, and calling external service by using the Service Adapter.
• The Native Controller manages calls to Native APIs that are used to get data from the mobile ecosystem. The Data Access Controller uses the data access adapter to connect to the data store.Web Application Mobile Application
Leverages services of powerful application servers Limited services
Fast processing Relatively slow processing
Multiuser support No support for multiple users
Built-in security mechanisms Not highly secure
Enough working (RAM) memory Limited working (RAM) memory
Matured optimization techniques Optimization techniques are not standardized
Slide 9
Business Layer Design Guidelines
Avoid long running requests that stop user operations. Handle them gracefully.
Do not cache heavy data in the business layer.
Provide additional validation instead of relying on the one provided by the presentation layer.
Optimize network requests by making fewer HTTP requests and thereby reduce network usage.
Minimize polling operations, for example, schedulers running periodically.
Prioritize network requests so that more important requests are made with inferior network connectivity.
Combine multiple requests at the application level to reduce network usage as against when multiple requests are made.
Use power manager APIs to check the battery status and then take processing decisions intelligently. It can also be used to check the battery status before executing heavy UI operations.
Leverage the permission model that is used by the device operating systems.
Use the least privilege model for system access.
Use correct computing algorithms. If the application does not handle critical data, approximations can be done. This will save extra processing that is required for data accuracy.
Avoid heavy loops as much as possible.
Achieve a balance between server and mobile side processing to avoid heavy processing on the mobile and still have minimum impact on the user experience.
Leverage SSL (Secure Socket Layer) for better security.
Slide 10
Mobile Ecosystem and Local Services Layer (Contd..)
• The local services layer provides services to the business layer. • The service includes calls to the mobile ecosystem and local data store. The data store needs to
be used diligently. • Using the local data store has advantages over network round-trip because it has numerous
benefits in terms of better user experience. • Native calls can be utilized to get more information from the operating system, which includes
information such as the battery status.• The data synchronization agent periodically synchronizes the locally cached data to the server.
Web Application Mobile Application
Huge data storing capacity Data storage is limited
Data is secure Data is relatively insecure
No data loss Possibility of data loss
Numerous data types are available Restricted data types are available
Data isolation can be easily managed Requires more efforts for data isolation
Data access is restricted Data access is open to any user of the mobile
Slide 11
Design Guidelines
Store data locally and synchronize periodically with the server to compensate for any loss of data from the mobile. Consider batch operation while you synchronize data.
Replicate local data to the server only if necessary.
Store sensitive data in encrypted format to avoid being read my malicious software.
Use local data for requirements such as storing user preferences as opposed to storing any sensitive data such as passwords.
Tune the database to increase the performance.
Understand data formats and map them correctly to those available on the local data storage.
Choose data formats correctly to avoid extra processing.
Other applications on a mobile can get easy access to files that are stored on the system. Take adequate care to secure this access and do not store any sensitive information on the file system.
Follow general guidelines to avoid database data injection.
The operating system may allow application to run in background or pause or even shutdown. These events need to be respected in advance.
Mobile Ecosystem and Local Services Layer
Slide 12
ConclusionThe concept of mobile applications is a new wave of technology. It’s just the beginning. There is still a long way to go. We must recognize that the IT industry has matured to a great extent and that research in various areas of IT will definitely benefit the development of mobile applications.
This document does not contain a complete list of all issues related to the development of mobile applications. It only provides important guidelines that are useful in designing better mobile applications.
Slide 13
About Cross Country InfotechCross Country Infotech (CCI) Pvt. Ltd. is a part of the Cross Country Healthcare (NYSE: CCRN) group of companies. CCI specializes in providing a gamut of IT/ITES services and is well equipped with technical expertise to provide smarter solutions to its customers. Some of our cutting-edge technology offerings include Mobile, Web and BI Application Development; ECM and Informix 4GL Solutions; and Technical Documentation, UI Design and Testing services.
Slide 14
Thank You!