0% found this document useful (0 votes)
77 views70 pages

West

This document provides details about the design and development of a mobile insurance application. It discusses the goals of creating a mobile app to efficiently manage insurance company records and provide reliable service to users. The document outlines the technologies used including Android and Java. It also describes the system requirements, design methodology, and business modeling approach. The overall purpose is to explain insurance policies to mobile users and help insurance agents conduct their daily business more easily.

Uploaded by

Mike Osei
Copyright
© Attribution Non-Commercial (BY-NC)
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% found this document useful (0 votes)
77 views70 pages

West

This document provides details about the design and development of a mobile insurance application. It discusses the goals of creating a mobile app to efficiently manage insurance company records and provide reliable service to users. The document outlines the technologies used including Android and Java. It also describes the system requirements, design methodology, and business modeling approach. The overall purpose is to explain insurance policies to mobile users and help insurance agents conduct their daily business more easily.

Uploaded by

Mike Osei
Copyright
© Attribution Non-Commercial (BY-NC)
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/ 70

InsuranceAgent

INSURANCEAGENT

CEC, CHIRALA

Page 1

InsuranceAgent

CEC, CHIRALA

Page 2

InsuranceAgent

CHAPTER 1
1. Introduction

The Insurance management system is a complete solution for organizations, which nee to manage insurance for their !ehicles, e"uipment, #uil ings, an other resources$ %rganizes an trac&s insurance !en ors an the policies pro!i e un er ifferent co!erage$ 'e are offering a ro#ust we# #ase insurance solution, which has the fle(i#ility of customizations to match the specific nee s of clients for achie!ing their #usiness goal of goo ser!ice an re!enue generation$ Insurance policy a ministration system consists of a mathematical notation that captures the relationship #etween policies an o#)ects an the entities that manage policies for those o#)ects$ *ence there is nee for an automate system, which can efficiently manage the company, recor s, pro!i es instant access an one that impro!es the pro ucti!ity$ As a result of this automate system, the acti!ities of the company are performe with in the stipulate time an the relia#le an efficient ser!ice is ensure to its users$

2. Overview
*ence there is nee for an automate system, which can efficiently manage the company, recor s, pro!i es instant access an one that impro!es the pro ucti!ity$ As a result of this automate system, the acti!ities of the company are performe with in the stipulate time an the relia#le an efficient ser!ice is ensure to its users$ The insurance company nee s to &eep trac& of etails of its target companies, agents, policyhol ers, their premium payments an the !arious pro ucts that are a!aila#le with it$ *ence it is un er tremen ous pressure maintaining their ay+to+ ay acti!ities, which is currently #eing one manually$ Entire recor s ha!e to #e up ate timely, e!en a slight mista&e coul complicate things$ It is !ery ifficult to han le #ul& ata since human memory is wea&er than electronic counterpart$ It is time consuming to summarize these etails to pro uce the reports$

CEC, CHIRALA

Page 3

InsuranceAgent

3. Techno og!

Technologies use are

,o#ile Application-

An roi %S .a!a /,0

". #!ste$ Co$%onents

This is a stan alone application e!elope for An roi phones$

&o'i e A%% ication(

The mo#ile application has #elow mo ules

1$ Show 2lans This mo ule is responsi#le to show the ifferent lic plans to the insurance agent$ An it3s also pro!i e the plans a ing option to the agent un er a new plan or e(isting plan$

CEC, CHIRALA

Page "

InsuranceAgent

4$ 2remium Calculator This mo ule is responsi#le to the premium #ase on the user input ata$

5$ Sen ing S,S an ,ails This mo ule is responsi#le to sen the plan etails to the user selecte mem#er through S,S or #y ,ail$

6$ *elp This mo ule is responsi#le to pro!i e the user gui e to the users who are new to this application$

7$ Settings This mo ule allows user to set some settings for the applications$

CEC, CHIRALA

Page )

InsuranceAgent

3. Introduction(

The mo#ile e!ices are #ecoming more an more popular an powerful an are pro!i ing a new notion of communication that we coul once only imagine$ A truly wireless mo#ile is new to the !ast ma)ority of computer users$ 'e &now wireless mo#ile phones, #ut the i ea of #eing a#le to connect to the Internet in a similar fashion is something with ramifications we8!e yet to fully realize$ The !ast ma)ority of us are still accustome to plugging a mo em into a phone #ac& to connect to the Internet remotely$ The enhancements in the technologies help us to ha!e the Internet accessing facilities e!en on the mo#iles$ %ur pro)ect is relate to in or er to organize an trac&s insurance !en ors an the policies pro!i e un er ifferent co!erage$ 'e are offering a ro#ust we# #ase

insurance solution, which has the fle(i#ility of customizations to match the specific nee s of clients for achie!ing their #usiness goal of goo ser!ice an re!enue

generation$ Insurance policy a ministration system consists of a mathematical notation that captures the relationship #etween policies an o#)ects an the entities that manage policies for those o#)ects$ *ence there is nee for an automate system, which can efficiently manage the company, recor s, pro!i es instant access an one that impro!es the pro ucti!ity$

CEC, CHIRALA

Page *

InsuranceAgent

". Techno og!


#o+tware Re,uire$ents +or -esigning( %perating System 2rogramming 0anguage I:E9'or&#ench :ata#ase S & 'in ows /29a#o!e or 0inu( .a!a Eclipse S;0ite An roi S & < or a#o!e$

#o+tware Re,uire$ents +or I$% e$entation( %perating System ,o#ile 2hone An roi 4$5 or a#o!e$ Any An roi ,o#ile phone

Hardware Re,uire$ents +or -esigning( 2rocessor *ar :is& RA, 2entium I= 6>G? 1 G? or more,

Hardware Re,uire$ents +or I$% e$entation( 2rocessor Internal ,emory RA, Screen size 2i(el :ensity -

AR, or a#o!e 1>> ,# or more 14@ ,# or more 6A>B54> 1@5ppi

CEC, CHIRALA

Page .

InsuranceAgent

CEC, CHIRALA

Page /

InsuranceAgent

CHAPTER 2
2.1 Ai$
1. This application is esigne to pro!i e the user easy to &now a#out the

policies$
2. This pro)ect is to ena#le the mo#ile users to !iew the plans an calculate

premiums with premium calculator$ 5$ The application must consi er the limitations of mo#ile e!ices$
4. The application must wor& properly without pro#lems on all targete

e!ices,

power supply an networ& support$

2.2 Pur%ose
The purpose of this pro)ect is to e(plain the policies of the company in ,o#ile$ The functionality assists in epen ent an e(clusi!e agents of an insurance company uring the course of con ucting their ay+to+ ay #usiness$ which is currently #eing one manually$ Entire recor s ha!e to #e up ate timely, e!en a slight mista&e coul complicate things$ It is !ery ifficult to han le #ul& ata since human memory is wea&er than electronic counterpart$ It is time consuming to summarize these etails to pro uce the reports$

CEC, CHIRALA

Page 0

InsuranceAgent

2.3 1easi'i it! #tud!(

All pro)ects are feasi#le C gi!en unlimite plague #y a scarcity of resources an

resources an

infinite timeD

Unfortunately, the e!elopment of computer+#ase system or pro uct is more li&ely ifficult eli!ery ates$ It is #oth necessary an ollars, an untol professional pru ent to e!aluate the feasi#ility of a pro)ect at the earliest possi#le time$ ,onths or years of effort, thousan s or millions of efinition phase$ em#arrassment can #e a!erte if an ill+concei!e system is recognize early in the

Eeasi#ility an ris& analysis are relate in many ways$ If pro)ect ris& is great the feasi#ility of pro ucing "uality software is re uce $ :uring pro uct engineering, howe!er, we concentrate our attention on four primary areas of interest-

CEC, CHIRALA

Page 12

InsuranceAgent

CHAPTER 3 #O1T3ARE E45I4EERI45 PARA-I5& APPLIE-

-E#I54 #PECI1ICATIO4

:esign of software in!ol!es concei!ing planning out an architectural esign an user interface esign in the

specifying the

e(ternally o#ser!a#le characteristics of the software pro uct$ 'e ha!e ata esign, esign process$ These are e(plaine in the following section$ The goals of esign process it to pro!i e a #lue print for implementation, testing, an maintenance acti!ities$

-ATA -E#I54

The primary acti!ity uring ata esign is to select logical representations of ata o#)ects i entifie uring re"uirement analysis an software analysis$ A ata ictionary e(plicitly on the elements of the ata structure$ A ata ictionary shoul #e esta#lishe an use to efine #oth ata an program esign$

CEC, CHIRALA

Page 11

InsuranceAgent

-E#I54 &ETHO-OLO56

The two #asic mo ern esign strategies employe in software esign are 1$ 4$ Top :own :esign ?ottom Up :esign

Top own :esign is #asically a ecomposition process, which focuses on the flow of control$ At later stages it concern itself with the co e pro uction$ The first step is to stu y the o!erall aspects of the tas&s at han an to #rea& it into a num#er of in epen ent mo ules$ The secon step is to #rea& each one of these mo ules further into in epen ent su#+mo ules$ The process is Repeate one to o#tain mo ules, which are small enough to group mentally an to co e in a straightforwar manner$ %ne important feature is that at each le!el the etails of the esign at the lower le!el are hi en$ %nly the necessary ata an control that must #e calle #ac& an forth o!er the interface are efine $ In a #ottom+up esign one first i entifies an in!estigates parts of esign that are most ifficult an necessary esigne ecision are ma e the remin er of the esign is tailore to fit aroun the esign alrea y chose for crucial part$ It !aguely represents a synthesis process e(plaine in pre!ious section$ %ne storage point of the top+ own metho is that it postpones etails of the ecision until the last stage of the ecision$ It allows ma&ing small esign changes when the esign is half way through$ There is anger that the specifications will #e incompati#le an this will not #e isco!ere until late in the esign process$ ?y contrast the #ottom+up strategy first focuses on the crucial part so that feasi#ility of the esign is teste at early stage$ In mi(ing top+ own an #ottom+up esign it often appears that we start in the mi le of the pro#lem an wor& our way #oth up an own there$ In a comple( eci e what functions are pro#lem, it is often ifficult to eci e how to mo ularize the !arious proce ures in such cases one might consi er a list of system inputs an necessary to process these inputs$ This is calle #ac& to front esign$ Similarly one can start with the re"uire outputs an wor& #ac&war s e!ol!ing so calle front+#ac&
CEC, CHIRALA Page 12

InsuranceAgent

esign$ 'e ha!e applie #oth the top own an #ottom up approach in our esign approach$

78#I4E## &O-ELI45
The information flow among #usiness function is mo ele in a way that

answers the following "uestions- what information ri!es the #usiness processF 'hat information is generate F 'hat generate itF 'here oes the information goF 'ho process itF

-ATA &O-ELI45
The information flow efine as a process of the #usiness mo eling is refine into a set of ata o#)ects that are nee e to support the #usiness$ The characteristics Gcalle attri#utesH of each o#)ect are i entifie an relationships #etween these o#)ects are efine $

PROCE## &O-ELI45
The ata o#)ects efine in the ata+mo eling phase are transforme to

achie!e the information flow necessary to implement a #usiness function$ 2rocessing escription are create for a ition, mo ifying, eleting, or retrie!ing a ata o#)ect$

THE LI4EAR #E98E4TIAL &O-EL


The linear se"uential mo el for software engineering some times calle the Iclassic mo elJ or the Iwater fall mo el,J the linear se"uential suggests a systematic, se"uential approach to software e!elopment that #egins at eth system le!el an process through analysis, esign, co ing, testing, an maintenance$ The linear se"uential mo el is the ol est an the most wi ely use para igm for software engineering$ ,o ele after the con!entional engineering cycle, the linear se"uential mo el encompasses the following acti!ities-

1: #6#TE&;I41OR&ATIO4 E45I4EERI45 A4- &O-ELLI45(


CEC, CHIRALA Page 13

InsuranceAgent

?ecause software is always part of a larger system Gor #usinessH, wor& #egins #y esta#lishing re"uirements for all system elements an then allocating some su#set of these re"uirements to software$ This system !iew is essential when software must interface with other elements such as har ware, people, an System engineering an system le!el with a small amount of top+le!el analysis an ata#ases$ analysis encompasses re"uirements gathering at the esign$ Information

engineering encompasses re"uirements gathering at the strategic #usiness le!el an at the strategic #usiness le!el an at the #usiness area le!el$

2: #O1T3ARE RE98IRE&E4T# A4AL6#I#(

The re"uirements gathering process is intensifie

an

focuse specifically on

software$ To un erstan the nature of the programs to #e #uilt, the software Engineer must un erstan the information omain for the software, as well as re"uire function, #eha!ior, performance, an inter facing$ Re"uirements for the #oth the system an the software are ocumente an re!iewe with the customer$

3: -E#I54(

Software esign is actually a multi step process that focuses on four istinct attri#utes of a programata structure, software architecture, interface representations, an proce ural etail$ The esign process translates re"uirements into a representation of the software that can #e assesse for "uality #efore co e generation #egins$ 0i&e re"uirements the esign is ocumente an #ecomes part of the software configuration$

CEC, CHIRALA

Page 1"

InsuranceAgent

": CO-E 5E4ERATIO4(

The esign must #e translate into a machine+rea a#le form$ The co e generation step performs this tas&$ If esign is performe in a etaile manner, co e generation can #e accomplishe mechanistically$

): TE#TI45(

%nce co e has #een generate , program testing process focuses on the logical internals of the software, assuring that all statements ha!e #een teste , an on the functional e(ternals that is, con ucting tests to unco!er errors an ensure that efine input will pro uce actual results that agree with re"uire results$

CEC, CHIRALA

Page 1)

InsuranceAgent

CEC, CHIRALA

Page 1*

InsuranceAgent

I4TRO-8CTIO4
System esign is a mo eling process$ It is a solution, how to approach to create a new system$ It can #e efine as a transition from user3s !iew to programmer3s or ata#ase person3s !iew$ The esign phase mainly epen s on the etaile specification in the feasi#ility stu y$ The system esign phase acts as a #ri ge #etween the re"uire specification an the implementation phase$

Erom a pro)ect management point of !iew software re"uirements into ata an software architecture$ :etaile

esign is

con ucte in two steps$ 2reliminary esign is concerne with the transformation of esign focuses on ata structure an refinement to the architectural representation that lea s to etaile algorithmic representation for software$

The ma)or steps in the esign phase are input esign, output esign, an ealing with co ing issue$ The !ery first step is esign of input an out put screen to the client re"uirements$ Ne(t comes the !arious issues that shoul #e ealt while co ing an the co e shoul #e such that it shoul #e compati#le with the real time en!ironment an Shoul #e generic in nature$ ".1 O7<ECTI=E I4 -E#I54I45 A4 I41OR&ATIO4 #6#TE&$ 'hat oes the system analyst inten e to achie!e uring the system esign stageF Following are the main objective of the system design phase:

CEC, CHIRALA

Page 1.

InsuranceAgent

".1.1 #%eci+! the ogica e e$ents


The system esign in!ol!es first, logical an then physical esign$ 'hen analyst formulates a logical esign an writes a etaile specification for the new system$ The physical esign, the acti!ity following the logical esign pro uces the software files an wor&ing system$ The system esign specification tells the programmer actually what the system oes$ The programmer in turn writes the

program, which accepts input an pro uces the re"uire output$

".1.2#u%%ort 'usiness activities


A fun amental o#)ecti!e of Ksystem esign3 is to ensure that it supports the #usiness acti!ities for which it was e!elope $ In other wor s, the computer an the communication technology specifie in the system shoul always #e secon ary to the result the system is inten e to pro uce$

".1.3 Ensure that a s!ste$ +eature $eets user re,uire$ents


User re"uirements are con!erte to system characteristics uring the esign$ 'e say that an information system meets user re"uirements if accomplishes the following 2resents information an instructions in accepta#le an effecti!e fashion 2ro uce the accurate result$ 2ro uces an accepta#le interface an metho of interface$ 2ercei!e #y the user as a relia#le system

CEC, CHIRALA

Page 1/

InsuranceAgent

".1." Provide detai ed so+tware deve o%$ent s%eci+ication


0i&e the features of information system the software must also #e carefully esigne $ System esign inclu es formulating the software specification$ The specification states input, output, the functions an algorithms use to perform them$ The esign specification escri#es the features of the system, the

components an elements of the system an their appearance to the users$ To many users the access of the system relates to whether they #elie!e that it has proper features$ The following are the features to #e esigne for the information system$

".2 I4P8T -E#I54

System analysis eci es the following input esign etails 1$ 'hat ata to #e use as inputF 4$ 'hat me ium to #e use F 5$ *ow the ata shoul #e arrange or co e F 6$ The ialogue that is use to gui e the user input ata$ 7$ ,etho s for performing input an error correction steps$

The input screens are esigne with e(treme care$ If #y mista&e some wrong ata is gi!en as input into the system, it must #e a#le to etect the mista&es an ta&e effecti!e measures to correct it, such as prompting the user of the incorrect ata or rectifying the error #y itself$

CEC, CHIRALA

Page 10

InsuranceAgent

".3 O8TP8T -E#I54


In output esign the emphasis is gi!en to the esign of har copy an a soft copy of information nee e for the users$ Efficient, intelligent an frien ly screens impro!e the relationship #etween client an the system for esign ma&ing$ System analysis eci es the following output esign etails1$ 'ho will recei!e the outputF 4$ 'hat is its planne useF 5$ *ow many etails are nee e F 6$ 'hen an how often the output is re"uire F 7$ #y which metho F

"." -E#I54 O1 PROCE-8RE


2roce ures specify what tas& is to #e performe an who is responsi#le for carrying them out$ Important proce ure inclu es the following

".".1 -ata entr! %rocedure It is a set of metho s for capturing transaction of ata entering into the information system$ *ere a lot of proce ures are use to get ata from the user starting from the registration to the nee $ The proce ures are esigne in such a way that it will ne!er insert any unwante ata into the ata#ase$

4.4.1.1 Runtime procedures Steps an actions are ta&en #y the system operator an in some cases en users who are interacting with the system, to get the esire output$

CEC, CHIRALA

Page 22

InsuranceAgent

1. Error hand ing Actions to #e ta&en when e(pecte result occur$ The system is capa#le to han le errors li&e in!ali ate, character fiel instea of num#er fiel etc$ The system ma&es mista&es use of prompts to inform the user of the incorrect ata entry$ 2. #ecurit! and 'ac> u% %rocedures These types of proce ures are resources against amage$ These types of proce ures are !ery important since the system may get into trou#le at any time$ Unauthorize access is not allowe #y the system$ A user can only access the system #y pro!i ing the correct login i an passwor $ esigne to pre!ent system an

CEC, CHIRALA

Page 21

InsuranceAgent

:iagramsUsecase Diagram for Agent Insurance

onStart name dob

insurencepolicy user1

insurencevalidity onStop Exit

ActivityDiagrams for AgentInsurence


CEC, CHIRALA Page 22

InsuranceAgent

validate

loginfa il

loginsucc ess Backup

end
policytyp e

Policy no Policy Status

policyvalid ity

end

CEC, CHIRALA

Page 23

InsuranceAgent

Class Diagram for AgentInsurence


"ainActivity onStart() onStop() exit() association

Agent name : String id : int dob : Date address : String agentInfor() generali!ation Policy id : int bound : String type : String name : String getPolicy() setPolicy() policy ype() dependency

Status id : int bound : String type : String name : String getStatus()

CEC, CHIRALA

Page 2"

InsuranceAgent

Se uence Diagram for AgentInsurence


agent re#uest process login policy status

bound re#uest responce

CEC, CHIRALA

Page 2)

InsuranceAgent

CEC, CHIRALA

Page 2*

InsuranceAgent

Overview o+ Android
A free, open source mo#ile platform$ A 0inu(+#ase , multiprocess, ,ultithrea e %S$ An roi is not a e!ice or a pro uct It3s not e!en limite to phones Lou coul #uil a :=R, a han hel G2S, an ,25 player, etc$ An roi is a software stac& for mo#ile e!ices that inclu es an operating system, mi leware an &ey applications$

The An roi S:M pro!i es the tools an A2Is necessary to #egin e!eloping applications on the An roi platform using the .a!a programming language$

! ! ! ! ! !

,a&es mo#ile e!elopment easy$ Eull phone software stac& inclu ing applications :esigne as a platform for software e!elopment An roi is open An roi is free Community support

<u ! 222) Google ac"uire An roi Inc$

) 4ov 222. %pen *an Set Alliance forme + Google, *TC, Intel, ,otorola, ;ualcomm,T+,o#ile

An roi is the %*A first pro uct 12 4ov 222. %*A release a pre!iew of the An roi %*A Oct?222/ Eirst :e!ice C T?&o'i e 51 was release $ 0atest C &otoro a &i estone release in In ia$

CEC, CHIRALA

Page 2.

InsuranceAgent

1eatures
! ! ! ! !

A%% ication +ra$ewor> ena#ling reuse an replacement of components -a vi> virtua $achine optimize for mo#ile e!ices Integrated 'rowser #ase on the open source 'e#Mit engine O%ti$i@ed gra%hics powere #y a custom 4: graphics li#raryN 5: graphics #ase on the %penG0 ES 1$> specification Ghar ware acceleration optionalH #9Lite for structure ata storage &edia su%%ort for common au io, !i eo, an still image formats G,2EG6, *$4@6, ,25, AAC, A,R, .2G, 2NG, GIEH 5#& Te e%hon! Ghar ware epen entH 7 uetooth, E-5E, 35, and 3i1i Ghar ware epen entH Ca$era, 5P#, co$%ass, and acce ero$eter Ghar ware epen entH Rich deve o%$ent environ$ent inclu ing a e!ice emulator, tools for e#ugging, memory an performance profiling, an a plugin for the Eclipse I:E

!
! ! ! ! !

0inu( Mernel An roi relies on 0inu( !ersion 4$@ for core system ser!ices such as ! ! ! ! ! ! security memory management process management networ& stac& ri!er mo el The &ernel also acts as an a#straction layer #etween the har ware an the rest of the software stac&$

Android Runti$e
! ! ! ! An roi inclu es a set of core li#raries that pro!i es most of the functionality a!aila#le in the core li#raries of the .a!a programming language$ E!ery An roi application runs in its own process, with its own instance of the :al!i& !irtual machine$ :al!i& has #een written so that a e!ice can run multiple =,s efficiently$ The :al!i& =, e(ecutes files in the :al!i& E(ecuta#le G$ e(H format which is optimize for minimal memory footprint$ The :al!i& =, relies on the 0inu( &ernel for un erlying functionality such as threa ing an low+le!el memory management$

CEC, CHIRALA

Page 2/

InsuranceAgent

Li'raries
An roi inclu es a set of C9COO li#raries use #y !arious components of the An roi system$ These capa#ilities are e(pose to e!elopers through the An roi application framewor&$ ! ! ! ! ! ! ! ! System C 0i#rary ,e ia 0i#rary Surface ,anager 0i#'e#Core SG0 5: li#raries Eree Type S;0ite

A%% ication 1ra$ewor>


! !
! ! ! ! !

! ! !

?eing a open e!elopment platform, An roi offers e!elopers the a#ility to #uil e(tremely rich an inno!ati!e applications$ :e!elopers ha!e full access to the same framewor& A2Is use #y the core applications$ =iews C use to #uil applications Glists, gri , #uttons, te(t #o(es an e!en em#e a#le we# #rowserH Content %roviders C ena#le applications to access ata from other applications or share their own ata$ Resource $anager C pro!i es access to non+co e resources such as localize strings, graphic an layout files$ 4oti+ication $anager C ena#les applications to isplay custom alerts in status #ar Activit! $anager C manages lifecycle of applications an pro!i es na!igation #ac&stac& An roi ships with a set of core applications inclu ing an email client, S,S program, calen ar, maps, #rowser, contacts, an others$ All applications are written using the .a!a programming language$

CEC, CHIRALA

Page 20

InsuranceAgent

Architecture

Anato$! o+ an Android A%% ication There are +our 'ui ding ' oc>s +or an Android a%% ication(
! ! ! !

Activit! + a single screen 7roadcast Receiver+ to e(ecute in reaction to an e(ternal e!entG2hone RingH #ervice + co e that is long+li!e an runs without a UIG,e ia 2layerH Content Provider + an application8s ata to #e share with other applications

Android 7ui ding 7 oc>s These are the $ost i$%ortant %arts o+ the Android APIs( ! Android&ani+est.A$ the control file+tells the system what to o with the top+le!el components

CEC, CHIRALA

Page 32

InsuranceAgent

Activities an o#)ect that has a life cycle+is a chun& of co e that oes some wor&

=iews an o#)ect that &nows how to raw itself to the screen

Intents a simple message o#)ect that represents an PintentionP to o something

4oti+ications is a small icon that appears in the status #arGS,S messagesH for alerting the user

#ervices is a #o y of co e that runs in the #ac&groun

-eve o%$ent Too s The An roi S:M inclu es a !ariety of custom tools that help you e!elop mo#ile applications on the An roi platform$Three of the most significant tools are1. Android E$u ator +A !irtual mo#ile e!ice that runs on our computer +use to

2. ". 4. #.

esign, e#ug, an test our applications in an actual An roi run+time en!ironment Android -eve o%$ent Too s P ugin +for the Eclipse I:E + a s powerful e(tensions to the Eclipse integrate en!ironment -a vi> -e'ug &onitor #ervice B--&#: +Integrate with :al!i& +this tool let us manage processes on an emulator an assists in e#ugging Android Asset Pac>aging Too BAAPT: C Constructs the istri#uta#le An roi pac&age files G$ap&H Android -e'ug 7ridge BA-7: C pro!i es lin& to a running emulator$ Can copy files to emulator, install $ap& files an run comman s$

CEC, CHIRALA

Page 31

InsuranceAgent

Li+ec!c e o+ activit!

Overview O+ C&L( C&L GEAtensi' e &ar>u% LanguageH is a set of rules for enco ing ocuments electronically$ It is efine in the /,0 1$> Specification pro uce #y the '5C, an se!eral other relate specifications, all gratis open stan ar s$ /,03s esign goals emphasize simplicity, generality, an usa#ility o!er the Internet It is a te(tual ata format, with strong support !ia Unico e for the languages of the worl $ Although /,03s esign focuses on ocuments, it is wi ely use for the representation of ar#itrary ata structures, for e(ample in we# ser!ices$

Advantages( The main usage of (ml Is we can store an retrie!e ata easily with the help of (ml$
CEC, CHIRALA Page 32

InsuranceAgent

C&L Introduction(

,I:2 e!ices ha!e memory constraints when it comes to co e, #oth in terms of the amount of co e you can store on the e!ice, an memory a!aila#le to applications at runtime$ So, &eeping the size of applications an features in chec& is of paramount importance to the .4,E e!eloper$ That3s where small+size /,0 parsers come into play$

C&L %arsers This section escri#es the /,0 parsing process an intro uces some small /,0 parsers for ,I:2$

C&L %arsing %rocess The /,0 parsing process operates in three phases1$ /,0 input processing$ In this stage, the application parses an !ali ates the source ocumentrecognizes an searches for rele!ant information #ase on its location or its tagging in the source ocumentN e(tracts the rele!ant information when it is locate N an , optionally, maps an #in s the retrie!e information to #usiness o#)ects$

4$ ?usiness logic han ling$ This is the stage in which the actual processing of the input information ta&es place$ It might result in the generation of output information$

5$ /,0 output processing$ In this stage, the application constructs a mo el of the ocument to #e generate with the :ocument %#)ect ,o el G:%,H$ It then either applies /S0T style sheets or irectly serializes to /,0$

CEC, CHIRALA

Page 33

InsuranceAgent

An application that implements such a processing mo el is calle an /,0 parser$ Lou can integrate an/,0 parser into your .a!a applications with the .a!a A2I for /,0 2rocessing G.A/2H$ .A/2 allowsapplications to parse an transform /,0 ocuments using an A2I that is in epen ent of any particular/,0 processor implementation$ Through a plug+in scheme, e!elopers can change /,0 processor implementations without altering their applications$

CEC, CHIRALA

Page 3"

InsuranceAgent

Overview o+ 5P#
The 5 o'a Positioning #!ste$ G5P#H is a space+#ase glo#al na!igation satellite system that pro!i es relia#le location an time information in all weather an at all times an anywhere on or near the Earth where there is an uno#structe line of sight to four or more G2S satellites$ It is maintaine #y the Unite States go!ernment an is freely accessi#le #y anyone with a G2S recei!er$ The G2S consists of three parts- the space segment, the control segment, an the user segment$ The U$S$ Air Eorce e!elops, maintains, an operates the space an control segments$ G2S satellites #roa cast signals from space, which each G2S recei!er uses to calculate its three+ imensional location Glatitu e, longitu e, an altitu eH plus the current time$ The space segment is compose of 46 to 54 satellites in me ium Earth or#it an also inclu es the #oosters re"uire to launch them into or#it$ The control segment is compose of a master control station, an alternate master control station, an a host of e icate an share groun antennas an monitor stations$ The user segment is compose of hun re s of thousan s of U$S$ an allie military users of the secure G2S 2recise 2ositioning Ser!ice, an tens of millions of ci!il, commercial, an scientific users of the Stan ar 2ositioning Ser!ice Gsee G2S na!igation e!icesH$

A%% ications
G2S has #ecome a wi ely use ai to na!igation worl wi e, an a useful tool for map+ma&ing, lan sur!eying, commerce, scientific uses, trac&ing an sur!eillance, an ho##ies such as geo caching an #y G2S is use way mar&ing$ The precise time reference pro!i e in many applications inclu ing the scientific stu y of

earth"ua&es an as a time synchronization source for cellular networ& protocols$ In a ition, G2S has, in the wor s of the we#site gps$go!, #ecome a mainstay of transportation systems worl wi e, pro!i ing na!igation for a!iation, groun , an maritime operations$ :isaster relief an emergency ser!ices epen upon G2S for location an timing capa#ilities in their life+sa!ing missions$ The accurate timing
CEC, CHIRALA Page 3)

InsuranceAgent

pro!i e

#y G2S facilitates e!ery ay acti!ities such as #an&ing, mo#ile phone

operations, an e!en the control of power gri s$ Earmers, sur!eyors, geologists an countless others perform their wor& more efficiently, safely, economically, an accurately using the free an open G2S signals$Q4R

8sing Location 'ased services BL7#: 0?S C ifferent technologies use to fin a e!ice3s current location Two main 0?S elements
Location &anager C pro!i es hoo&s to the 0?S Location

Providers C represents a

ifferent location+fin ing

technology use to etermine the e!ice3s current location$ Using 0ocation ,anager, %#tain current location Trac& mo!ement Set pro(imity alerts Ein a!aila#le 0ocation 2ro!i ers #e ecting a Location Provider :epen ing on e!ice, there may #e se!eral technologies that An roi can use to etc$$H To get an instance of a specific pro!i er, String providerName !ocation"anager.#$S%$R&'()*R+ location"anager.get$rovider,providerName-+ etermine the current location with ifferent capa#ilitiesGpower consumption, monetary cost, accuracy an a#ility to etermine altitu e, spee

!ocation$rovider gps$rovider

CEC, CHIRALA

Page 3*

InsuranceAgent

This is useful to etermine a#ilities of a particular pro!i er$ Two common 0ocation pro!i ers 0ocation,anager$G2SS2R%=I:ER 0ocation,anager$NET'%RMS2R%=I:ER

1inding !our ocation Access to the location+#ase ser!ice is han le #y 0ocation ,anager system ser!ice$ !ocation"anager location"anager ,!ocation"anagergetSystemService,!&./0(&N%S*R'(.*-+ A one or more uses+permissions in manifest$ 1uses2permission android:name 3android.permission./..*SS%F(N*%!&./0(&N456 1uses2permission android:name 3android.permission./..*SS%.&/RS*%!&./0(&N456 To fin the last location fi( etermine #y a particular pro!i er, !ocation location location"anager.get!ast7nown!ocation,!ocation"anager.#$S%$R&'()*R-+ 0ocation o#)ect contains all the position information which can #e retrie!e using get metho s$ get0astMnown0ocationGH oes not as& the pro!i er to up ate the current position$ 8sing 5eocoder Geoco ing lets you translate #etween street a resses an map coor inates$ 0oo&ups are one on the ser!er, so Internet permission is re"uire $ Geoco er class pro!i es access to two geoco ing functions Eorwar geoco ing C fin s coor inates of an a ress Re!erse geoco ing C fin s street a ress for gi!en points$ #eocoder gc new #eocoder ,this8 !ocale.get)efault,--+

Reverse 5eocoding ,ap coor inates to a ress #eocoder gc new #eocoder ,this8 !ocale.get)efault,--+

CEC, CHIRALA

Page 3.

InsuranceAgent

try 9 !ist1/ddress6 addresses null+ addresses = gc.getFromLocation(lat, lng, 10); String:uilder sb new String:uilder,-+

if,addresses.si;e,-6<9 Address address addresses.get,<-+

for,int i <+ i<address.getMaxAddressLineIndex();i==sb.append,address.getAddressLine(i)-.append,3>n3-+ sb.append,address.getLocality,--.append,3>n3-+ sb.append,address.getPostal ode,--.append,3>n3-+ sb.append,address.get o!ntry"ame,--+ ? lat!ongString ? catch ,*@ception e- 9 !og.d,3#eocoder38e.get"essage,--+ ? sb.toString,-+

1orward 5eocoding A ress to map co+or inates #eocoder gc new #eocoder ,this8 !ocale.AS-+ String street/ddress 31B< Riverside )rive8 New CorD8 New CorD3+

!ist1/ddress6 locations null+ try 9 locations= gc.getFromLocation"ame(streetAddress, 10); ? catch ,(&*@ception e- 9 !og.d,3geocoder38 e.get"essage,--+
CEC, CHIRALA Page 3/

InsuranceAgent

Creating &a% 7ased activities ,ap=iew pro!i es an i eal user interface option for presenting geographical ata$ Using ,ap=iew, we can create Acti!ities that feature an interacti!e map$ ,ap !iews offer full programmatic control of map isplay Gzoom, location an isplay mo es+satellite, street an traffic !iewsH Classes to support An roi maps
&a%=iew C the ,ap =iew control$ &a%Activit! C #ase class to create a new Acti!ity that can inclu e

,ap =iew$
OverLa! C to annotate maps$ 2ro!i es Can!as to raw on ,ap=iew$ &a%Contro er C to control map Gcenter location an zoom le!elsH &!LocationOver a! C special %!erlay use to isplay the current

position an orientation of e!ice$ Ite$i@edOver a!s an Over a!Ite$s C together use to create a layer of map mar&ers, isplaye using :rawa#les an te(t$

CEC, CHIRALA

Page 30

InsuranceAgent

CEC, CHIRALA

Page "2

InsuranceAgent

#!ste$ Co$%onents The mo#ile application has #elow mo ules

1. #how P ans This mo ule is responsi#le to show the ifferent lic plans to the insurance agent$ An it3s also pro!i e the plans a ing option to the agent un er a new plan or e(isting plan$

2. Pre$iu$ Ca cu ator This mo ule is responsi#le to the premium #ase on the user input ata$

3. #ending #&# and &ai s This mo ule is responsi#le to sen the plan etails to the user selecte mem#er through S,S or #y ,ail$

". He % This mo ule is responsi#le to pro!i e the user gui e to the users who are new to this application$

). #ettings This mo ule allows user to set some settings for the applications$

CEC, CHIRALA

Page "1

InsuranceAgent

CEC, CHIRALA

Page "2

InsuranceAgent

package net.pms.insagent; import import import import import import import import import import import android.app.Activity; android.app.AlertDialog; android.content.ContentValues; android.content.DialogInterface; android.content.Intent; android.database.Cursor; android.database.sqlite.SQ iteDatabase; android.os.!undle; android.vie".Vie"; android."idget.#dit$e%t; android."idget.$oast;

public class &pdate'lan e%tends Activity ( private String planId; private #dit$e%t edit'lanId) edit'lan*ame) edit'lanSummary) edit'lan+roupId; ,-verride protected void onCreate.!undle savedInstanceState/ ( super.onCreate.savedInstanceState/; setContentVie".0.layout.updateplan/; edit'lanId 1 .#dit$e%t/ findVie"!yId.0.id.edit'lanId/; edit'lan*ame 1 .#dit$e%t/ findVie"!yId.0.id.edit'lan*ame/; edit'lanSummary 1 .#dit$e%t/ findVie"!yId.0.id.edit'lanSummary/; edit'lan+roupId 1 .#dit$e%t/ findVie"!yId.0.id.edit'+roupId/; 2 ,-verride protected void onStart./ ( super.onStart./; planId 1 t3is.getIntent./.getString#%tra.4planid4/; try ( D!5elper db3elper 1 ne" D!5elper.t3is/; SQ iteDatabase db 1 db3elper.get0eadableDatabase./; Cursor plan 1 db.query.Database.' A*S6$A! #6*A7#) null) 4 planid 1 84) ne" String9: (planId2) null) null) null/; if.plan.move$o;irst.//( edit'lanId.set$e%t.plan.getString.plan.getColumnInde%.Database.' A*6I D///; edit'lan*ame.set$e%t.plan.getString.plan.getColumnInde%.Database.' A* 6*A7#///; edit'lanSummary.set$e%t.plan.getString.plan.getColumnInde%.Database.' A*6S&77A0<///; edit'lan+roupId.set$e%t.plan.getString.plan.getColumnInde%.Database.' A*6+0-&'6ID///; 2

CEC, CHIRALA

Page "3

InsuranceAgent

plan.close./; db.close./; db3elper.close./; 2 catc3 .#%ception e/ ( $oast.make$e%t.t3is) 4#rror..4=e.get7essage./) $oast. #*+$56 -*+/.s3o"./; 2 2 public void update'lan.Vie" vie"/ ( try ( D!5elper db3elper 1 ne" D!5elper.t3is/; SQ iteDatabase db 1 db3elper.get>ritableDatabase./; ContentValues values 1 ne" ContentValues./; values.put.Database.' A*6*A7#) edit'lan*ame.get$e%t./.toString.//; values.put.Database.' A*6S&77A0<) edit'lanSummary.get$e%t./.toString.//; long ro"s 1 db.update.Database.' A*S6$A! #6*A7#) values) 4 planid 1 84) ne" String9: (planId2/; db.close./; if .ro"s ? @/ $oast.make$e%t.t3is) 4&pdated +roup SuccessfullyA4) $oast. #*+$56 -*+/.s3o"./; else $oast.make$e%t.t3is) 4SorryA Could not update +roupA4) $oast. #*+$56 -*+/.s3o"./; 2 catc3 .#%ception e/ ( $oast.make$e%t.t3is) 4#rror..&pdate 'lan +roup 4=e.get7essage./) $oast. #*+$56 -*+/.s3o"./; 2 2 public void delete'lan.Vie" vie"/ ( AlertDialog.!uilder builder 1 ne" AlertDialog.!uilder.t3is/; builder.set7essage.4Are you sure you "ant to delete t3is 'lan84/ .setCancelable.false/ .set'ositive!utton.4<es4) ne" DialogInterface.-nClick istener./ ( public void onClick.DialogInterface dialog) int id/ ( deleteCurrent'lan./; 2 2/ .set*egative!utton.4*o4) ne" DialogInterface.-nClick istener./ ( public void onClick.DialogInterface dialog) int id/ ( dialog.cancel./; 2 2/; AlertDialog alert 1 builder.create./; alert.s3o"./; 2 public void deleteCurrent'lan./ ( try (

CEC, CHIRALA

Page ""

InsuranceAgent

D!5elper db3elper 1 ne" D!5elper.t3is/; SQ iteDatabase db 1 db3elper.get>ritableDatabase./; int ro"s 1 db.delete.Database.' A*S6$A! #6*A7#) 4 planid184) ne" String9: ( planId2/; db3elper.close./; if . ro"s 11 B/ ( $oast.make$e%t.t3is) 4'lan Deleted SuccessfullyA4) $oast. #*+$56 -*+/.s3o"./; t3is.finis3./; 2 else $oast.make$e%t.t3is) 4Could not delete 'lanA4) $oast. #*+$56 -*+/.s3o"./; 2 catc3 .#%ception e/ ( $oast.make$e%t.t3is) 4Delete 'lan #rror..4=e.get7essage./) $oast. #*+$56 -*+/.s3o"./; 2 2 public void vie"'lanDetails.Vie" vie"/ ( CC$oast.make$e%t.t3is) 4 ist All 'lans...4) $oast. #*+$56 -*+/.s3o"./; Intent intent 1 ne" Intent.t3is) ist'lanDetails.class/; intent.put#%tra.4planid4) planId/; startActivity.intent/; 2 2

CEC, CHIRALA

Page ")

InsuranceAgent

package net.pms.insagent; import import import import import import import import import import import android.app.Activity; android.app.AlertDialog; android.content.ContentValues; android.content.DialogInterface; android.content.Intent; android.database.Cursor; android.database.sqlite.SQ iteDatabase; android.os.!undle; android.vie".Vie"; android."idget.#dit$e%t; android."idget.$oast;

public class &pdate'lan+roup e%tends Activity ( private String groupId; private #dit$e%t edit+roupId) edit+roup*ame; ,-verride protected void onCreate.!undle savedInstanceState/ ( super.onCreate.savedInstanceState/; setContentVie".0.layout.updateplangroup/; edit+roupId 1 .#dit$e%t/ findVie"!yId.0.id.edit+roupId/; edit+roup*ame 1 .#dit$e%t/ findVie"!yId.0.id.edit+roup*ame/; 2 ,-verride protected void onStart./ ( super.onStart./; groupId 1 t3is.getIntent./.getString#%tra.4groupid4/; try ( D!5elper db3elper 1 ne" D!5elper.t3is/; SQ iteDatabase db 1 db3elper.get0eadableDatabase./; Cursor group 1 db.query.Database.' A*+0-&'S6$A! #6*A7#) null) 4 groupid 1 84) ne" String9: (groupId2) null) null) null/; if.group.move$o;irst.//( CCeditAcno.set$e%t.account.getString.account. getColumnInde%.Database.ACC-&*$S6AC*-///; edit+roupId.set$e%t.group.getString.group.getColumnInde%.Database.' A *+0-&'6ID///; edit+roup*ame.set$e%t.group.getString.group.getColumnInde%.Database.' A*+0-&'6*A7#///; 2 group.close./; db.close./; db3elper.close./; 2 catc3 .#%ception e/ ( $oast.make$e%t.t3is) 4#rror..4=e.get7essage./) $oast. #*+$56 -*+/.s3o"./; 2 2 public void update'lan+roup.Vie" vie"/ ( try (

CEC, CHIRALA

Page "*

InsuranceAgent

D!5elper db3elper 1 ne" D!5elper.t3is/; SQ iteDatabase db 1 db3elper.get>ritableDatabase./; ContentValues values 1 ne" ContentValues./; values.put.Database.' A*+0-&'6*A7#) edit+roup*ame.get$e%t./.toString.//; long ro"s 1 db.update.Database.' A*+0-&'S6$A! #6*A7#) values) 4 groupid 1 84) ne" String9: (groupId2/; db.close./; if .ro"s ? @/ $oast.make$e%t.t3is) 4&pdated +roup SuccessfullyA4) $oast. #*+$56 -*+/.s3o"./; else $oast.make$e%t.t3is) 4SorryA Could not update +roupA4) $oast. #*+$56 -*+/.s3o"./; 2 catc3 .#%ception e/ ( $oast.make$e%t.t3is) 4#rror..&pdate 'lan +roup 4=e.get7essage./) $oast. #*+$56 -*+/.s3o"./; 2 2 public void delete'lan+roup.Vie" vie"/ ( AlertDialog.!uilder builder 1 ne" AlertDialog.!uilder.t3is/; builder.set7essage.4Are you sure you "ant to delete t3is +roup84/ .setCancelable.false/ .set'ositive!utton.4<es4) ne" DialogInterface.-nClick istener./ ( public void onClick.DialogInterface dialog) int id/ ( deleteCurrent+roup./; 2 2/ .set*egative!utton.4*o4) ne" DialogInterface.-nClick istener./ ( public void onClick.DialogInterface dialog) int id/ ( dialog.cancel./; 2 2/; AlertDialog alert 1 builder.create./; alert.s3o"./; 2 public void deleteCurrent+roup./ ( try ( D!5elper db3elper 1 ne" D!5elper.t3is/; SQ iteDatabase db 1 db3elper.get>ritableDatabase./; int ro"s 1 db.delete.Database.' A*+0-&'S6$A! #6*A7#) 4 groupid184) ne" String9: ( groupId2/; db3elper.close./; if . ro"s 11 B/ ( $oast.make$e%t.t3is) 4+roup Deleted SuccessfullyA4) $oast. #*+$56 -*+/.s3o"./; t3is.finis3./; 2 else

CEC, CHIRALA

Page ".

InsuranceAgent

$oast.make$e%t.t3is) 4Could not delete +roupA4) $oast. #*+$56 -*+/.s3o"./; 2 catc3 .#%ception e/ ( $oast.make$e%t.t3is) 4Delete 'lan +roup #rror..4=e.get7essage./) $oast. #*+$56 -*+/.s3o"./; 2 2 public void listAll'lans.Vie" vie"/ ( CC$oast.make$e%t.t3is) 4 ist All 'lans...4) $oast. #*+$56 -*+/.s3o"./; Intent intent 1 ne" Intent.t3is) istAll'lans.class/; intent.put#%tra.4groupid4) groupId/; startActivity.intent/; 2 2

CEC, CHIRALA

Page "/

InsuranceAgent

package net.pms.insagent; import import import import android.content.Conte%t; android.database.sqlite.SQ iteDatabase; android.database.sqlite.SQ ite-pen5elper; android.util. og;

public class D!5elper e%tends SQ ite-pen5elper ( public static final int D!6V#0SI-* 1 B; public static final String D!6*A7# 1 4myinsagent.db4; public D!5elper.Conte%t ct%/ ( super.ct%) D!6*A7#) null) D!6V#0SI-*/; 2 ,-verride public void onCreate.SQ iteDatabase db/ ( create$ables.db/; 2 ,-verride public void on&pgrade.SQ iteDatabase arg@) int argB) int argD/ 2 public void create$ables.SQ iteDatabase database/ ( String groups6table6sql 1 4create table 4 = Database.' A*+0-&'S6$A! #6*A7# = 4 . 4 = Database.' A*+0-&'S6ID = 4 integer primary key autoincrement)4 = Database.' A*+0-&'6ID = 4 $#E$)4 = Database.' A*+0-&'6*A7# = 4 $#E$/4; String plans6table6sql 1 4create table 4 = Database.' A*S6$A! #6*A7# = 4 . 4 = Database.' A*S6ID = 4 integer key autoincrement)4 = Database.' A*6ID = 4 $#E$)4 = Database.' A*6*A7# = 4 $#E$)4 = Database.' A*6S&77A0< = 4 $#E$)4 = Database.' A*6+0-&'6ID= 4 $#E$/4; try ( database.e%ecSQ .groups6table6sql/; database.e%ecSQ .plans6table6sql/; og.d.4D! 5elper4)4$ables createdA4/; 2 catc3.#%ception e%/ ( og.d.4D! 5elper4) 4#rror in D!5elper.onCreate./ F 4 = e%.get7essage.//; 2 2 2

primary

CEC, CHIRALA

Page "0

InsuranceAgent

package net.pms.insagent; import Gava.util.Array ist; import import import import import import import import import android.0.string; android.content.ContentValues; android.content.Conte%t; android.database.Cursor; android.database.sqlite.SQ iteDatabase; android.util. og; android."idget.ArrayAdapter; android."idget.Date'icker; android."idget.Spinner; String ' A*+0-&'S6$A! #6*A7# 1 String ' A*+0-&'S6ID146id4; String ' A*+0-&'6ID 1 4groupid4; String ' A*+0-&'6*A7# 1 4groupname4; String String String String String String ' ' ' ' ' ' A*S6$A! #6*A7# 1 4plans4; A*S6ID146id4; A*6ID 1 4planid4; A*6*A7# 1 4planname4; A*6S&77A0< 1 4summary4; A*6+0-&'6ID 1 4groupid4;

public class Database ( public static final 4plangroups4; public static final public static final public static final public public public public public public static static static static static static final final final final final final

public static 'lan+roups cursor$o'lan+roups.Cursor groups/ ( 'lan+roups group 1 ne" 'lan+roups./; group.set+roupId.groups.getString.groups.getColumnInde%.' A*+0-&'6ID/ //; group.set+roup*ame.groups.getString.groups.getColumnInde%.' A*+0-&'6* A7#///; return group; 2 static void populate+roups.Spinner spinner+roups/ ( Conte%t conte%t 1 spinner+roups.getConte%t./; D!5elper db3elper 1 ne" D!5elper.conte%t/; SQ iteDatabase db 1 db3elper.get0eadableDatabase./; Cursor groups 1 db.query.Database.' A*+0-&'S6$A! #6*A7#) null) null)null) null) null) null/; Array istH'lan+roups? list 1 ne" Array istH'lan+roups?./; CC adapter.setDropDo"nVie"0esource.android.0.layout.simple6spinner6dropd o"n6item/; "3ile .groups.move$o*e%t.// ( 'lan+roups group 1 Database.cursor$o'lan+roups.groups/; list.add.group/; 2 groups.close./; db.close./; db3elper.close./; public

CEC, CHIRALA

Page )2

InsuranceAgent

ArrayAdapterH'lan+roups? adapter 1 ne" ArrayAdapterH'lan+roups?.conte%t) android.0.layout.simple6spinner6item)list/; spinner+roups.setAdapter.adapter/; 2 public static boolean update'lan.SQ iteDatabase db) String planId) String plan*ame) String summary) String groupId/ ( try ( db.e%ecSQ . 4 update 4 = Database.' A*S6$A! #6*A7# = 4 set planname 1 I4 = plan*ame = 4I) summary 1 I4 = summary =4I "3ere 4 = Database.' A*6ID = 4 1 4 = planId/; return true; 2 catc3.#%ception e%/ ( og.d.4'lans4) 4#rror in &pdate 'lans 4 = e%.get7essage.//; return false; 2 2 public static String get'lan+roupId.Spinner spinner+roups/ ( 'lan+roups group 1 .'lan+roups/ spinner+roups.getSelectedItem./; return group.get+roupId./; 2 public static String getDate;romDate'icker.Date'icker dp/ ( return dp.get<ear./ = 4J4 = dp.get7ont3./ = B = 4J4 = dp.getDay-f7ont3./; 2 public static boolean add'lan.Conte%t conte%t) String planId) String plan*ame) String summary) String groupId/ ( D!5elper db3elper 1 null; SQ iteDatabase db 1 null; try ( db3elper 1 ne" D!5elper.conte%t/; db 1 db3elper.get>ritableDatabase./; db.begin$ransaction./; CC e%ecute insert command ContentValues values 1 ne" ContentValues./; values.put.Database.' A*6ID) planId/; values.put.Database.' A*6*A7#) plan*ame/; values.put.Database.' A*6S&77A0<) summary/; values.put.Database.' A*6+0-&'6ID) groupId/; null) values/; long ro"id 1 db.insert.Database.' A*S6$A! #6*A7#)

og.d.4'lans4)4Inserted into ' A*S 4 = ro"id/; if . ro"id A1 JB/ ( CC update 'lans $able boolean done 1 Database.update'lan.db) planId) plan*ame) summary) groupId/; og.d.4'lans4)4&pdated 'lans $able4/; if . done / ( db.set$ransactionSuccessful./;

CEC, CHIRALA

Page )1

InsuranceAgent

db.end$ransaction./; return true; 2 else ( db.end$ransaction./; return false; 2 else 2 2 return false;

catc3.#%ception e%/ ( og.d.4Account4) 4#rror in add$ransaction JJ?4 = e%.get7essage.//; return false; 2 finally ( if . db A1 null KK db.is-pen.// ( db.close./; 2 2 CC add'lan 2

CEC, CHIRALA

Page )2

InsuranceAgent

package net.pms.insagent; import import import import import import import import import public ( android.app.Activity; android.app.AlertDialog; android.content.Conte%t; android.content.DialogInterface; android.content.DialogInterface.-nClick istener; android.content.Intent; android.vie".7enu; android.vie".7enuItem; android."idget.$oast; class !aseActivity e%tends Activity implements -nClick istener final Conte%t conte%t 1 t3is; public boolean onCreate'anel7enu.int featureId) 7enu menu/ ( menu.add.4Start4/; menu.add.4About &s4/; menu.add.45elp4/; menu.add.4Quit4/; return super.onCreate'anel7enu.featureId) menu/;2 ,-verride public boolean on-ptionsItemSelected.7enuItem item/ ( String selected7enu 1 item.get$itle./.toString./; CC$oast.make$e%t.getApplicationConte%t./) 4 4=selected7enu) B@/.s3o"./; if.selected7enu.equals.4Start4//( finis3./; startActivity.ne" Intent.getApplicationConte%t./) ;irstActivity.class//; 2 else if.selected7enu.equals.4About &s4// ( startActivity.ne" Intent.getApplicationConte%t./) AboutActivity.class//; 2 else if.selected7enu.equals.45elp4// ( startActivity.ne" Intent.getApplicationConte%t./) 5elpActivity.class//; 2 else if.selected7enu.equals.4Quit4// ( AlertDialog.!uilder alertDialog!uilder 1 ne" AlertDialog.!uilder.conte%t/; alertDialog!uilder.set$itle.4Insurance Agent4/; alertDialog!uilder.set7essage.40eally to #%it84/.setCancelable.false/.set'ositive!utton.4<es4) t3is/.set*egative!utton.4*o4) t3is/; AlertDialog dialog 1 alertDialog!uilder.create./; dialog.s3o"./; 2 return super.on-ptionsItemSelected.item/; 2 ,-verride public void onClick.DialogInterface arg@) int argB/ ( CC$oast.make$e%t.conte%t) 4Selected is 4 = argB) $oast. #*+$56 -*+/.s3o"./; if.argB 11 JB/ t3is.finis3./; 2 2

CEC, CHIRALA

Page )3

InsuranceAgent

CEC, CHIRALA

Page )"

InsuranceAgent

#6#TE& TE#TI45 A4- I&PLE&E4TATIO4


..1 #6#TE& TE#TI45

Ta&ing !arious &in s of testing errors are again unco!ere

ata plays a !ital role in system testing$ After an correcte #y using the a#o!e steps an

preparing the test ata, the system un er stea y is teste using the test ata$ 'hile corrections are also note for future use$ The system has #een !erifie an !ali ate #y running the test ata an li!e ata$ Eirst the system is teste with some sample test ata that are generate for the li!e ata$ with &nowle ge of the possi#le range of !alues that are re"uire to hol #y the fiel 3s the system runs successfully for the gi!en test ata an

T!%es o+ Testing 8nit Testing *ere we test each mo ule in i!i ually an integrate the o!erall system$ Unit testing focuses !erification efforts e!en in the smallest unit of software esign in each mo ule$ This is also &nown as Imo ule testing$J$ The mo ules of the system are teste separately$ This testing is carrie out in the programming style itself$ In this testing each mo ule is focuse to wor& satisfactorily as regar to e(pecte output from the mo ule there are some !ali ation chec&s for the fiel s$ Integration testing :ata can #e lost across an interface, one mo ule can ha!e an a !erse effect on the other su# functions, when com#ine testing is one with simple ata an may not pro uce the esire functions$ Integrate testing is the systematic testing to unco!er the errors with an interface$ This e!elope system has run successfully with this simple ata$ The nee for integrate system is to fin the o!erall system performance$

CEC, CHIRALA

Page ))

InsuranceAgent

T!%es o+ Integration Testing 1. To% -own Integration ,o ules are integrate #y mo!ing ownwar through the control hierarchy, #eginning with the main program mo ule$

2. 7otto$ u% Integration ?ottom up Integration is implemente with the following steps 0ow+le!el mo ules are com#ine into clusters into clusters that perform a specific Software su#+function$ A ri!er Gi$e$,H the control program for testing is written to coor inate test case input an output$ The cluster is teste $ :ri!ers are remo!e an clusters are com#ine mo!ing upwar in the program structure$

=a idation testing At the culmination of #lac& #o( testing, software is completely assem#le s a pac&age$ Interfacing errors ha!e #een unco!ere an the correct an final series of tests, i$e$, !ali ation tests #egins$ =ali ation test is efine with a simple efinition that !ali ation succee s when the software function in a manner that can #e reasona#ly accepte #y the customer$

Out%ut Testing After performing !ali ation testing, the ne(t step is output testing of the propose system$ Since the system cannot #e useful if it oes not pro uce the re"uire output$ As&ing the user a#out the format in which the system s re"uire tests the output isplaye or generate #y the system un er consi eration$ *ere the output
CEC, CHIRALA Page )*

InsuranceAgent

format is consi ere in two ways one is on screen format an the other one is a printe format the output format on the screen is foun to #e correcte as the format was esigne in the system has accor ing to the user nee s$ As for the har copy the output comes accor ing to the specification re"ueste #y the user$ *ere the output testing oes not result in any correction in the system$

Test data and Out%ut( Ta&ing !arious &in soft ata plays a !ital role in system testing$ After

preparing the test ata system un er stu y is teste using the test ata$ 'hile testing, errors are again unco!ere an correcte #y using the a#o!e steps an corrections are also note for future use$ The system has #een !erifie an !ali ate #y running test ata an li!e ata$ 8ser acce%tance testing( User acceptance testing of the system is the &ey factor for the success of any system$ A system un er consi eration is teste for user acceptance #y constantly &eeping in touch with the prospecti!e system at the time of e!elopment an ma&ing change whene!er re"uire $ This is one with regar to the input screen esign an output screen esign$

..2 #6#TE& I&PLE&E4TATIO4 Implementation is the stage of the pro)ect where the theoretical esign is turne into a wor&ing system$ At this stage the main wor& loa , the greatest uphea!al an the ma)or impact on the e(isting system shifts to the user epartment$ If the implementation is not carefully planne an controlle it can cause chaos an confusion$

CEC, CHIRALA

Page ).

InsuranceAgent

Implementation inclu es all those acti!ities that ta&e place to con!ert from the ol system to the new one$ The new system may #e totally new, replacing an e(isting manual or automate system or it may #e a ma)or mo ification to an e(isting system$ 2roper implementation is essential to pro!i e a relia#le system to meet the organization re"uirements$ Successful implementation may not guarantee impro!ement in the organization using the new system, #ut improper installation will pre!ent it$ The process of putting the e!elope system in actual use is calle system implementation$ This inclu es all those acti!ities that ta&e place to con!ert from the ol system to the new system$ The system can #e implemente only after thorough testing is one an if it is foun to #e wor&ing accor ing to the specifications$ The system personnel chec& the feasi#ility of the system$

The implementation stage in!ol!es following tas&s$ Careful planning$ In!estigation of system an constraints$ :esign of metho s to achie!e the changeo!er$ Training of the staff in the changeo!er phase$ E!aluation of the changeo!er metho $ The most crucial stage is achie!ing a new successful system an gi!ing confi ence on the new system for the user that it will wor& efficiently an effecti!ely$ It in!ol!es careful planning, in!estigation of the current system an its constraints on implementation, esign of metho s to achie!e the changeo!er$ The more comple( the system #eing implemente , the more in!ol!e will #e the system analysis an the esign effort re"uire )ust for implementation$ The system implementation has three main aspects$ They are e ucation an training, system testing an changeo!er$

I$% e$entation Procedures Implementation of software refers to the final installation of the pac&age in its real en!ironment, to the satisfaction of the inten e users an the operation of the system$ In many organizations some one who will not #e operating it, will
CEC, CHIRALA Page )/

InsuranceAgent

commission the software e!elopment pro)ect$ The people who are not sure that the software is meant to ma&e their )o# easier$ In the initial stage, they ou#t a#out the software #ut we ha!e to ensure that the resistance oes not #uil up as one has to ma&e sure that

The acti!e user must #e aware of the #enefits of using the system Their confi ence in the software is #uilt up 2roper gui ance is imparte to the user so that he is comforta#le in using the application$

?efore going ahea an !iewing the system, the user must &now that for !iewing the result, the ser!er program shoul #e running in the ser!er$ If the ser!er o#)ect is not up running on the ser!er, the actual processes won3t ta&e place$

8ser Training To achie!e the o#)ecti!es an #enefits e(pecte from computer #ase system, it is essential for the people who will #e in!ol!e to #e confi ent of their role in the new system$ As systems #ecome more comple(, the nee for e ucation an training is more an more important$

E ucation is complementary to training$ It #rings life to formal training #y e(plaining the #ac&groun to the resources for them$ E ucation in!ol!es creating the right atmosphere an moti!ating user staff$ E ucation sections shoul encourage participation from all staff with protection for in i!i uals for group criticism$ E ucation shoul start will #efore any e!elopment wor& to ena#le users to maintain or to regain the a#ility to participate in the e!elopment of their system$

E ucation information can ma&e training more interesting an

more

un erstan a#le$ The aim shoul always #e to ma&e in i!i ual feel that they can still
CEC, CHIRALA Page )0

InsuranceAgent

ma&e all important contri#utions, to e(plain how they participate in ma&ing system changes, an to show that the computer an computer staff o not operate in isolation, #ut are of the same organization$

Training on the A%% ication After pro!i ing the necessary #asic training on the computer awareness the users will ha!e to #e traine on the new application software$ This will gi!e the un erlying philosophy of the use of the new system such as the screen flow, screen esign, type of help on the screen, type of errors while entering the ata the correspon ing !ali ation chec& at each entry an the ways to correct the ata entere $ It shoul then co!er information nee e #y the specific user9groups to use the system or part of the system while imparting the training of the program on the application$ This training may #e ifferent across ifferent user groups an across ifferent le!els of hierarchy$

O%erationa -ocu$entation %nce the implementation plan is eci e , it is essential that the user of the system is ma e familiar an comforta#le with the en!ironment$ E ucation in!ol!es right

atmosphere T moti!ating the user$ A ocumentation pro!i ing the whole operations of the system is #eing e!elope $ The system is e!elope in such a way that the user can wor& with it in a well consistent way$ The system is e!elope user frien ly so that the user can wor& the system from the tips gi!en in the application itself$ Useful tips an gui ance is gi!en insi e the application itself to help the user$ Users ha!e to #e ma e aware that what can #e achie!e with the new system an how it increases the performance of the system$ The user of the system shoul #e gi!en a general i ea of the system #efore he uses the system$ #!ste$ &aintenance
CEC, CHIRALA Page *2

InsuranceAgent

The maintenance phase of the software cycle is the time in which a Software pro uct performs useful wor&$ After a system is successfully implemente , it shoul #e maintaine in a proper manner$ System maintenance is an important aspect in the software e!elopment life cycle$ The nee for system maintenance is for it to ma&e a apta#le to the changes in the system en!ironment$ There may #e social, technical an other en!ironmental changes, which affects a system, which is #eing isplays an mo e of interaction, upgra ing the implemente $ Software pro uct enhancements may in!ol!e pro!i ing new functional capa#ilities, impro!ing user performance characteristics of the system$ So only through proper system maintenance proce ures, the system can #e a apte to cope up with these changes$

Software maintenance is of course, far more than Ifin ing mista&esJ$ 'e may efine maintenance #y escri#ing four acti!ities that are un erta&en to after a program is release for use$ The first maintenance acti!ity occurs #ecause it is unreasona#le to assume that software testing will unco!er all latent errors in a large software system$ :uring the use of any large program, errors will occur an #e reporte to the e!eloper$ The process that inclu es the iagnosis an correction of one or more errors is calle corrective maintenance. The secon acti!ity that contri#utes to a efinition of maintenance occurs #ecause of the rapi change that is encountere in e!ery aspect of computing$ an commonplace$ Therefore, adaptive maintenance+ an acti!ity that mo ifies software to properly interfere with a changing en!ironment is #oth necessary

The thir acti!ity that may #e applie to a efinition of maintenance occurs when a software pac&age is successful$ As the software is use , recommen ations for new capa#ilities, mo ifications to e(isting functions, an general enhancements are recei!e from users$ To satisfy re"uests in this category, perfective maintenance is performe $ This acti!ity accounts for the ma)ority of all effort e(pen e on software maintenance$ The fourth maintenance acti!ity occurs when software is change to impro!e future maintaina#ility or relia#ility, or to pro!i e a #etter #asis for future

CEC, CHIRALA

Page *1

InsuranceAgent

enhancements$ %ften calle preventive maintenance8 this acti!ity is characterize #y re!erse engineering an re+engineering techni"ues$

CEC, CHIRALA

Page *2

InsuranceAgent

CEC, CHIRALA

Page *3

InsuranceAgent

CEC, CHIRALA

Page *"

InsuranceAgent

CEC, CHIRALA

Page *)

InsuranceAgent

CEC, CHIRALA

Page **

InsuranceAgent

CEC, CHIRALA

Page *.

InsuranceAgent

CEC, CHIRALA

Page */

InsuranceAgent

Images use in this Application are-

CEC, CHIRALA

Page *0

InsuranceAgent

7i'i ogra%!(

http-99 e!eloper$an roi $com9s &9apiS iff9<9changes9an roi $location$0ocation,anag er$html http-99)a!a$sun$com9)a!ase9 ownloa s9in e($)sp http-99www$eclipse$org9 ownloa s9Eclipse http-99www$forum$no&ia$com9

CEC, CHIRALA

Page .2

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy