BIT 3209 MOBILE PROGRAMMING  (WEEKEND) KCA Past Paper

UNIVERSITY EXAMINATIONS: 2013/2014
ORDINARY EXAMINATION FOR THE BACHELOR OF SCIENCE
IN INFORMATION TECHNOLOGY
BIT 3209 MOBILE PROGRAMMING (WEEKEND)
DATE: AUGUST, 2014 TIME: 2 HOURS
INSTRUCTIONS: Answer Question ONE and any other TWO

QUESTION ONE
a) Android operating systems for mobile devices has been increasing its market share
worldwide. Describe one reason that explains this trend. (2 Marks)
b) Describe three main Mobile Market Players. (3 Marks)
c) Describe four limitations that are associated with mobile devices. (4 Marks)
d) Briefly explain the meaning of the term ‘XML element’ in the context of mobile
programming. Write sample code to illustrate your answer. (4 Marks)
e) Write an XML or java code that displays the following output when executed in an
emulator or real device. (5 Marks)


f) Briefly explain the purpose of ‘ Setcontentview(R.layout.main)’ in the following
lines of code ( 2 Marks)
Public void oncreate (Bundle savedinstancesstate)
{ …..
Setcontentview(R.layout.main);
… }
g) Briefly explain how you understand the following XML lines of code. (5 Marks)


h) Distinguish between views and view groups, give one exmple for each case
(5 Marks)
QUESTION TWO
a) Briefly explain the meaning of the following terms as used in mobile programming.
write a sample code that demonstrates implementation each term
i) layout. (4 Marks)
ii) intent (4 Marks)
iii) activity (4 Marks)
b) Describe the following layouts in the context user interface of a mobile application.
draw a diagram for each case to demonstrate your understand. (4 Marks)
i) Relative Layout
ii) Frame layout

c) Briefly explain how you understand the following lines of code as used in mobile
programming (4 Marks)


QUESTION THREE
a) Briefly describe three functions of a manifest XML file in mobile programming.
(3 Marks)
b) Explain how you understand the following lines of code in a manifest file.
(5 Marks)


c) Describe the contents of the following directories in an android application.
i) src/ (2 Marks)
ii) res/ (2 Marks)
iii) bin/ (2 Marks)
d) Write XML or Java code that displays the following output of a mobile application.
(6 Marks)


QUESTION FOUR
a). Briefly explain functions of the components of mobile application
i) Content provider (2 Marks)
ii) Service (2 Marks)
iii) Notification (2 Marks)
b) Describe the meaning of the statement ‘ life cycle of an activity’ in the context of
mobile programming. (2 Marks).
c) Explain five states that an activity goes through during a life cycle. Draw a well
labelled diagram that illustrates the lifecycle. (10 Marks)
d) Describe the meaning of the term Killable states in the context of mobile
programming. Give one example of a killable state. (2 Marks)
QUESTION FIVE
a) State and explain any two selection controls that are used to implement user interface of a
mobile application. Write a sample code to demonstrate their implements. ( 5 Marks)
b) Explain the meaning of the following lines of code in the context of mobile
programming. (6 Marks)
public class Lab2 extends Activity
{
public void onCreate(Bundle savedInstanceState)
{ super.onCreate(savedInstanceState);
TextView view = new TextView(this);
view.setText(“Welcome to KCA University Mobi Site \n”);
setContentView(view); } }
c) Describe the process of compiling an android application. draw a well labeled diagram
that illustrates the process. (6 Marks)
d) Android platform consists of three components. Describe each of these components
(3 Marks)

(Visited 115 times, 1 visits today)
Share this:

Written by