Anand Na|k
uevelopmenL Managerţ Cross CounLry lnfoLech
llde 2
1hls documenL dlscusses Lhe archlLecLure of Lyplcal moblle appllcaLlonsŦ lL also provldes
a comparlson beLween Web and moblle appllcaLlonsŦ ueslgners and ArchlLecLs can
beneflL from Lhe deslgn guldellnes presenLed ln Lhls documenLŦ 1he documenL does noL
dlscuss nonLechnlcal lssuesţ such as lssues relaLed Lo resources or developmenL
meLhodologlesţ whlch are faced durlng Lhe developmenL of moblle appllcaLlonsŦ
llde 3
W 1he developmenL of moblle appllcaLlons ls noL newŦ 1he concepL ls aL leasL a decade
oldŦ Poweverţ ln Lhe recenL pasLţ lL has grown aL an enormous speedŦ
W 1he upsurge of smarL phones and moblle operaLlng sysLems are some of Lhe facLors
LhaL drlve Lhls growLhŦ ln addlLlonţ Lhe developer communlLy ls encouraged Lo see
dlrecL access Lo cusLomers Lhrough varlous channels such as AppLoreţ markeLplaceţ
and oLher channelsŦ
W 1he sofLware lndusLry has maLured Lo a greaL exLenLţ buL Lhe area of moblle
appllcaLlon developmenL sLlll opens up loads of lssuesŦ
W Perds of Web appllcaLlon developers are [umplng lnLo moblle appllcaLlon
developmenL wlLh Lhe baggage of Lhelr Web developmenL experlenceŦ
llde 4
Jat Are Mob||e App||cat|ons?
W Any sofLware appllcaLlon LhaL uses a moblle phone as a plaLform Lo execuLe speclflc
Lasks ls called a moblle appllcaLlonŦ
W Moblle appllcaLlons can be naLlve appllcaLlons LhaL are wrlLLen by uslng devlceŴbased
sofLware LoolsŦ
W 1hey could be browserŴbased appllcaLlons LhaL use P1MLţ !avacrlpLţ or cascadlng
sLyle sheeLs or Lhey could be MŴbased appllcaLlonsŦ
W Moblle appllcaLlons dlffer from WebŴbased appllcaLlons ln varlous aspecLsţ a
developmenL Leam needs Lo conslder Lhese dlfferences whlle maklng deslgn
W 1he addlLlon of moblllLy requlres conslderlng varlous facLorsţ whlch lnclude neLwork
connecLlvlLyţ devlce capablllLlesţ power supplyţ wlde range of user lnLerfacesţ and
numerous plaLformsŦ
llde 3
Mob||e App||cat|on Arc|tecture and Des|gn
Moblle user
ul ComponenLs LvenL Pandlers
8uslness Layer ConLroller
uaLa Access
uaLa Access
naLlve C
Local uaLa
Loca| Serv|ces
Mob||e Lcosystem
ervlces ueployed on AppllcaLlon erver
llde 6
Þresentat|on Layer (ContdŦŦŦ)
W 1he presenLaLlon layer prlmarlly has Lwo maln componenLsŸLhe ul componenLs and Lhe evenL
W 1he ul componenLs are vlslble Lo Lhe moblle userţ for exampleţ a LexL boxŦ
W 1he ul componenLs generaLe evenLs when acLed upon by Lhe userŦ
W 1hese evenLs are caughL by Lhe evenL handlers for furLher processlngŦ 1he deslgn of Lhe
presenLaLlon layer ls lmporLanL for a rlch user experlenceŦ
Jeb App||cat|on Mob||e App||cat|on
lxed layouL orlenLaLlon ÞorLralL or landscape layouLs
lxed seL of resoluLlons/screen slzes varleLy of resoluLlons and screen slzes
no local cachlng Local cachlng
Lnough real esLaLe avallable LlmlLed amounL of real esLaLe
Landard lnpuL meLhods new Ǝ cumbersome lnpuL meLhods
ConslsLenL neLwork avallablllLy wlLh enough bandwldLh lnconslsLenL neLwork avallablllLy wlLh llmlLed bandwldLh
L and encrypLlon supporL ome old devlces may have lssues
ConLlnuous power supply uses baLLery power
llde 7
Þresentat|on Layer
Des|gn Gu|de||nes
lf your appllcaLlon needs Lo be porLable across devlcesţ lL
should use plaLformŴlndependenL Lechnologles such as
1lLanlum and ÞhoneCapŦ
ueslgn your appllcaLlon Lo flL Lhe porLralL and Lhe landscape
1he real esLaLe avallable on Lhe moblle has a dlrecL relaLlon
wlLh user experlenceŦ ueslgn your appllcaLlons Lo use Lhls
scarce resourceŦ ueclde Lhe LargeL resoluLlons and operaLlng
sysLems and flL Lhe layouL accordlnglyŦ
use conslsLenL and slmple navlgaLlonŦ uo noL make lL overly
use local cachlng as a mechanlsm Lo lmprove user
experlenceŦ uo noL cache senslLlve daLa ln unencrypLed
formaLŦ uo noL rely on Lhe cached daLa Lo a greaL exLenLŦ
use excepLlons carefullyŦ ulfferenLlaLe beLween excepLlons
and Lake approprlaLe acLlonsŦ
1he moblle keyboard ls noL as easy Lo operaLe as a deskLop
keyboardŦ ?our ul deslgn should allow users Lo enLer
mlnlmum amounL of daLaŦ
Conslder deslgnlng for Louch screen and sLylusŴenabled devlcesŦ
keep Lhe renderlng loglc separaLe from Lhe buslness loglcŦ
valldaLe Lhe lnpuL and handle valldaLlon errors correcLlyŦ
Avold uslng references Lo exLernal resources such as lmages
because lL makes a neLwork call and Lhereby consumes neLwork
8ecause compleLe u8Ls are noL usually vlslbleţ lL makes a
phlsher's llfe easyŦ 1he appllcaLlon should aLLempL Lo use small
u8Ls LhaL are compleLely vlslbleŦ
Cn screen keyboard used for lnpuL reduces Lhe real esLaLe
avallableţ llmlLlng Lhe vlslblllLy of Lhe screenŦ ul deslgn should
Lake care of LhlsŦ
navlgaLlon varles dependlng on Lhe devlce for example lÞhone
has only one physlcal buLLon for navlgaLlon whlle ln androldţ back
buLLon and conLexL menu makes lL easler Lo navlgaLeŦ
Avold uslng heavy medla flles Lo conserve baLLery powerŦ
llde 8
8us|ness Layer (ContdŦŦ)
W 1he buslness layer conLalns Lhe 8uslness Layer ConLrollerţ 8uslness Layer CrchesLraLlonţ naLlve
ConLrollerţ and Lhe ervlce AdapLerŦ
W 1he 8uslness Layer ConLroller provldes an lnLerface Lo Lhe presenLaLlon layer Lo lnLeracL wlLh
Lhe buslness loglcŦ
W 1he 8uslness Layer CrchesLraLlon carrles ouL varlous buslness operaLlonsţ such as geLLlng
lnformaLlon from Lhe moblle ecosysLem Lhrough Lhe naLlve ConLrollerţ geLLlng local daLa
Lhrough Lhe uaLa Access ConLrollerţ and calllng exLernal servlce by uslng Lhe ervlce AdapLerŦ
W 1he naLlve ConLroller manages calls Lo naLlve AÞls LhaL are used Lo geL daLa from Lhe moblle
ecosysLemŦ 1he uaLa Access ConLroller uses Lhe daLa access adapLer Lo connecL Lo Lhe daLa
Jeb App||cat|on Mob||e App||cat|on
Leverages servlces of powerful appllcaLlon servers LlmlLed servlces
asL processlng 8elaLlvely slow processlng
MulLluser supporL no supporL for mulLlple users
8ullLŴln securlLy mechanlsms noL hlghly secure
Lnough worklng (8AM) memory LlmlLed worklng (8AM) memory
MaLured opLlmlzaLlon Lechnlques CpLlmlzaLlon Lechnlques are noL sLandardlzed
llde 9
8us|ness Layer
Des|gn Gu|de||nes
Avold long runnlng requesLs LhaL sLop user operaLlonsŦ
Pandle LhemgracefullyŦ
uo noL cache heavy daLa ln Lhe buslness layerŦ
Þrovlde addlLlonal valldaLlon lnsLead of relylng on Lhe
one provlded by Lhe presenLaLlon layerŦ
CpLlmlze neLwork requesLs by maklng fewer P11Þ
requesLs and Lhereby reduce neLwork usageŦ
Mlnlmlze polllng operaLlonsţ for exampleţ schedulers
runnlng perlodlcallyŦ
ÞrlorlLlze neLwork requesLs so LhaL more lmporLanL
requesLs are made wlLh lnferlor neLwork connecLlvlLyŦ
Comblne mulLlple requesLs aL Lhe appllcaLlon level Lo
reduce neLwork usage as agalnsL when mulLlple
requesLs are madeŦ
use power manager AÞls Lo check Lhe baLLery sLaLus
and Lhen Lake processlng declslons lnLelllgenLlyŦ lL can
also be used Lo check Lhe baLLery sLaLus before
execuLlng heavy ul operaLlonsŦ
Leverage Lhe permlsslon model LhaL ls used by Lhe devlce
operaLlng sysLemsŦ
use Lhe leasL prlvllege model for sysLem accessŦ
use correcL compuLlng algorlLhmsŦ lf Lhe appllcaLlon does
noL handle crlLlcal daLaţ approxlmaLlons can be doneŦ 1hls
wlll save exLra processlng LhaL ls requlred for daLa
Avold heavy loops as much as posslbleŦ
Achleve a balance beLween server and moblle slde
processlng Lo avold heavy processlng on Lhe moblle and
sLlll have mlnlmumlmpacL on Lhe user experlenceŦ
Leverage L (ecure ockeL Layer) for beLLer securlLyŦ
llde 10
Mob||e Lcosystem and Loca| Serv|ces Layer (ContdŦŦ)
W 1he local servlces layer provldes servlces Lo Lhe buslness layerŦ
W 1he servlce lncludes calls Lo Lhe moblle ecosysLem and local daLa sLoreŦ 1he daLa sLore needs Lo
be used dlllgenLlyŦ
W uslng Lhe local daLa sLore has advanLages over neLwork roundŴLrlp because lL has numerous
beneflLs ln Lerms of beLLer user experlenceŦ
W naLlve calls can be uLlllzed Lo geL more lnformaLlon from Lhe operaLlng sysLemţ whlch lncludes
lnformaLlon such as Lhe baLLery sLaLusŦ
W 1he daLa synchronlzaLlon agenL perlodlcally synchronlzes Lhe locally cached daLa Lo Lhe serverŦ
Jeb App||cat|on Mob||e App||cat|on
Puge daLa sLorlng capaclLy uaLa sLorage ls llmlLed
uaLa ls secure uaLa ls relaLlvely lnsecure
no daLa loss ÞosslblllLy of daLa loss
numerous daLa Lypes are avallable 8esLrlcLed daLa Lypes are avallable
uaLa lsolaLlon can be easlly managed 8equlres more efforLs for daLa lsolaLlon
uaLa access ls resLrlcLed uaLa access ls open Lo any user of Lhe moblle
llde 11
Des|gn Gu|de||nes
Lore daLa locally and synchronlze perlodlcally wlLh Lhe
server Lo compensaLe for any loss of daLa from Lhe
moblleŦ Conslder baLch operaLlon whlle you synchronlze
8epllcaLe local daLa Lo Lhe server only lf necessaryŦ
Lore senslLlve daLa ln encrypLed formaL Lo avold belng
read my mallclous sofLwareŦ
use local daLa for requlremenLs such as sLorlng user
preferences as opposed Lo sLorlng any senslLlve daLa
such as passwordsŦ
1une Lhe daLabase Lo lncrease Lhe performanceŦ
undersLand daLa formaLs and map Lhem correcLly Lo
Lhose avallable on Lhe local daLa sLorageŦ
Choose daLa formaLs correcLly Lo avold exLra processlngŦ
CLher appllcaLlons on a moblle can geL easy access Lo
flles LhaL are sLored on Lhe sysLemŦ 1ake adequaLe care Lo
secure Lhls access and do noL sLore any senslLlve
lnformaLlon on Lhe flle sysLemŦ
ollow general guldellnes Lo avold daLabase daLa
1he operaLlng sysLem may allow appllcaLlon Lo run ln
background or pause or even shuLdownŦ 1hese evenLs
need Lo be respecLed ln advanceŦ
Mob||e Lcosystem and Loca| Serv|ces Layer
llde 12
1he concepL of moblle appllcaLlons ls a new wave of LechnologyŦ lL's [usL Lhe beglnnlngŦ
1here ls sLlll a long way Lo goŦ We musL recognlze LhaL Lhe l1 lndusLry has maLured Lo a
greaL exLenL and LhaL research ln varlous areas of l1 wlll deflnlLely beneflL Lhe
developmenL of moblle appllcaLlonsŦ
1hls documenL does noL conLaln a compleLe llsL of all lssues relaLed Lo Lhe developmenL
of moblle appllcaLlonsŦ lL only provldes lmporLanL guldellnes LhaL are useful ln deslgnlng
beLLer moblle appllcaLlonsŦ
llde 13
About Cross Country nfotec
Cross CounLry lnfoLech (CCl) ÞvLŦ LLdŦ ls a parL of Lhe Cross CounLry PealLhcare (n?Lť
CC8n) group of companlesŦ CCl speclallzes ln provldlng a gamuL of l1/l1L servlces and ls
well equlpped wlLh Lechnlcal experLlse Lo provlde smarLer soluLlons Lo lLs cusLomersŦ
ome of our cuLLlngŴedge Lechnology offerlngs lnclude Moblleţ Web and 8l AppllcaLlon
uevelopmenLŤ LCM and lnformlx 4CL oluLlonsŤ and 1echnlcal uocumenLaLlonţ ul
ueslgn and 1esLlng servlcesŦ
llde 14
@ank ¥ou!