0% found this document useful (0 votes)
14 views8 pages

Object Oriented Design MS

This document outlines the examination paper for the Bachelor of Science in Computer Science at Kiriri Women's University for the 2017/2018 academic year. It includes instructions for candidates, various questions related to object-oriented analysis and design, and topics such as classes, inheritance, polymorphism, and design methodologies. The document also contains specific case studies and diagrams related to software development concepts.

Uploaded by

Peter Obiria
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views8 pages

Object Oriented Design MS

This document outlines the examination paper for the Bachelor of Science in Computer Science at Kiriri Women's University for the 2017/2018 academic year. It includes instructions for candidates, various questions related to object-oriented analysis and design, and topics such as classes, inheritance, polymorphism, and design methodologies. The document also contains specific case studies and diagrams related to software development concepts.

Uploaded by

Peter Obiria
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 8

Kasarani Campus

Off Thika Road


Tel. 2042692 / 3
P. O.
Box 49274, 00100
NAIROBI
Westlands Campus
Pamstech House
Woodvale Grove
Tel. 4442212
Fax: 4444175
KIRIRI WOMENS’ UNIVERSITY OF SCIENCE AND TECHNOLOGY
UNIVERSITY EXAMINATION, 2017/2018 ACADEMIC YEAR
THIRD YEAR, SECOND SEMESTER EXAMINATION
FOR THE DEGREE OF BACHELOR OF SCIENCE
(COMPUTER SCIENCE)
Date: APRIL, 2018
Time:
KCS 307 OBJECT ORIENTED ANALYSIS AND DESIGN
INSTRUCTIONS TO CANDIDATES_________________________________________________

ANSWER QUESTION ONE (COMPULSORY) AND ANY OTHER TWO QUESTIONS_____

QUESTION ONE (30 MARKS)

a) Briefly discuss the following terms (10 Marks)


i) class
It is a template for creating objects. A class describes a collection of related objects (i.e., instances of the
classes). Objects of the same class have common operations and a common set of possible states. The
concept of class is closely related to the concept of abstract data type. (Data structures and operations that
can be performed on it) A class description includes definitions of operations on objects of the class, the
possible set of states.
ii) Inheritance
A class D inherits from class B if D's objects form a subset of B's objects.
Class D's objects must support all of the class B's operations (but perhaps are carried out in a special way).
Class D may support additional operations and an extended state (i.e., more information fields).
Class D is called a subclass or a child or derived class.
Class B is called a superclass or a parent or base class.
iii) Polymorphism
The concept of polymorphism (literally "many forms") The ability of objects to respond differently to the
same message or a function call. Ability to appear in many forms. Polymorphism appears in several forms.
iv) Encapsulation
Encapsulation is a way of packaging information. Encapsulation is hiding the details of the
implementation of an object so that there are no dependencies on the particular implementation. Allows

Page 1 of 8
the programmer to present clearly specified interfaces around the services they provide. The programmer
can decide what should be hidden and what is intended to be visible.
v) Abstraction
Abstraction refers to the act of representing essential features without including the background details or
explanations (Showing only essential details). It is the art of concentrating on the essential and ignoring the
non-essential.

Read the following Excerpt and answer questions that follow


A motor dealer makes an order for various items. An order comprises a list of required parts each identified
by part-number, name-of-item, and item-price. It is possible to perform operations like adding an item in the
order list, deleting an item from the list and printing the total value of the order.

Required:

b) Identify the classes in the above description and construct a class diagram showing any relationship,
the operations and data members. (4 Marks)
Answer
Classes: -Item
Class: ITEM
DATA:
part_number
name_of_item
item_price
OPERATIONS:
add()
delete()
print_total()
c) State the THREE visibility mode that can be used in the class. (3 Marks)
-private
-public
-protected
d) Differentiate the following design methodologies (4 Marks)

i) Functional decomposition (Top-Down)


The whole system is characterized by a single function, and then the function is decomposed into a
set of functions in a process of stepwise refinement.

ii) Functional composition (bottom-up)

You can have different components of functions such as that from a function library
You can compose them into a module with a more significant function.

e) Describe your understanding of the term object Orientation giving examples. (4 Marks)
It is a kind of thinking methodology

Page 2 of 8
Everything in the world is an object;
Any system is composed of objects (certainly a system is also an object);
The evolution and development of a system is caused by the interactions among the objects
inside or outside the system
e.g
A flower, a tree, an animal
A student, a professor
A desk, a chair, a classroom, a building
A university, a city, a country
The world, the universe
A subject such as CS, IS, Math, History, …
Object-Orientation is a kind of design methodology(OOA/OOD)
"Object orientation provides a new paradigm for software construction.
In this new paradigm, objects and classes are the building blocks, while methods, messages and
inheritance produce the primary mechanisms".-Ann L. Winbald, Samuel D. Edwards and David
R. King in the book, "Object Oriented Software".
f) The following Use Case diagram contains several use cases. Describe each dependency (not use
case) between the use cases present in the diagram in one sentence each. Number the dependencies
for this purpose. Differentiate between the “include” concept and the “extend” concept relationship.
(5 Marks)

Page 3 of 8
QUESTION TWO (20 MARKS)

a) State THREE goals of the design phase of object oriented design (3 Marks)
b) Explain TWO risks associated with object oriented development. (4 Marks)
c) Use the following case to identify Classes and Operations. Associate the operations with the
appropriate classes. (5 Marks)
Computerized Telephone Book for a university

The telephone book should contain entries for each person in the university community--student,
professor, and staff member. Users of the directory can look up entries. In addition, the administrator of
the telephone book can, after supplying a password, insert new entries, delete existing entries, modify
existing entries, print the telephone book, and print a listing of all students or of all faculty.
d) Identify Actors and Use cases for the following problem statement and develop Use case and
sequence diagrams. (8 Marks)
Course Registration System

At the beginning of each semester, students may request a course catalogue containing a list of
course offerings for the semester. In addition, Course Catalogue includes information such as
professor, department and prerequisites. The new system will allow students to select four course
offerings for the coming semester. In addition, each student will indicate two alternative choices.
No course offering will have more than ten students or fewer than three students. The system will
cancel the course with fewer than three students. After the registration process, the registration
system sends information to the billing system. The billing system will bill the student for the
semester. The system will allow professors to indicate the teaching courses and to see the
students signed up for the courses. For each semester, students can change the schedule during
a period of time. Students will access the system during this time to add or drop courses.

Page 4 of 8
QUESTION THREE (20 MARKS)

a) Differentiate between the following terms:

i) Object model and object structure (2 Marks)


ii) Object based programming and object oriented programming (2 Marks)
iii) Object oriented decomposition and object oriented design (2 Marks)
iv) Structured analysis and object oriented analysis (2 Marks)
v) Private and protected declaration (2 Marks)
b) Define and briefly describe the term inheritance and explain the types of inheritance. (5 Marks)

QUESTION FOUR (20 MARKS)

QUESTION FOUR (20 MARKS)

Page 5 of 8
a) List and explain five different types of software models that can be used in software development in
OOD. (10 Marks)
Possible answers:
 v-model
 waterfall model
 spiral model
 prototyping model
 build and fix model
 RAD model etc.
(Student should discuss five models briefly)

b) Describe and Discuss UML Structure diagrams and Behavior diagrams in detail. (10 Marks)
Possible answers:
Structure diagrams emphasize the things that must be present in the system being modeled. They include:
 Class diagram: describes the structure of a system by showing the system's classes, their
attributes, and the relationships among the classes.
 Component diagram: describes how a software system is split up into components and shows the
dependencies among these components.
 Composite structure diagram: describes the internal structure of a class and the collaborations that
this structure makes possible.
 Deployment diagram: describes the hardware used in system implementations and the execution
environments and artifacts deployed on the hardware.
 Object diagram: shows a complete or partial view of the structure of a modeled system at a specific
time.
 Package diagram: describes how a system is split up into logical groupings by showing the
dependencies among these groupings.
 Profile diagram: operates at the metamodel level to show stereotypes as classes with the
<<stereotype>> stereotype, and profiles as packages with the <<profile>> stereotype. The
extension relation (solid line with closed, filled arrowhead) indicates what metamodel element a
given stereotype is extending.

Behaviour diagrams emphasize what must happen in the system being modeled.
They include:

Page 6 of 8
 Activity diagram: describes the business and operational step-by-step workflows of components in
a system. An activity diagram shows the overall flow of control.
 UML state machine diagram: describes the states and state transitions of the system.
 Use case diagram: describes the functionality provided by a system in terms of actors, their goals
represented as use cases, and any dependencies among those use cases.

QUESTION FIVE (20 MARKS)

a) Differentiate between the following terms:

i) Static and dynamic binding (2 Marks)

ii) Coupling and cohesion (2 Marks)


Coupling deals with interactions between objects or software components while cohesion deals with the
interactions within a single object or software component. Highly cohesive components can lower coupling
because only a minimum of essential information need to b passed between components
b) Identify and briefly describe any FIVE diagrams used in Booch methodology. (10 Marks)
1. Class diagrams.
2. Object diagrams.
3. State transition diagrams.
4. Module diagrams.
5. Process diagrams.
6. Interaction diagrams.

c) Give a detailed account of your understanding of the term Unified approach (6 Marks)

Establishes a unifying and unitary framework by utilizing UML

The processes are:

– Use case driven development.


– Object oriented analysis.
– Object oriented design.
– Incremental development and prototyping
– Continuous testing.

Methods and technologies employed include:

– UML
– Layered approach.

– Repository.
– CBD.
– Object oriented Analysis.

Page 7 of 8
– Identify actors.
– Develop a simple process model.
– Develop the use case.
– Develop interaction diagrams.
– Identify classes.
– Object oriented design
– Design classes, attributes, methods etc
– Design the access layer.
– Design the prototype user interface.
– User satisfaction and usability tests.
– Iterate and refine the design.
– Continuous testing
UML – modeling language
Repository
– Allows maximum reuse of previous experience.
– Should be accessible by many people.
– Layered approach
– The business layer.
– Displaying results.
– Data access details
– The user interface or view layer. Responding to user interaction.
– Displaying business objects.
– The access layer.
– Translate request.
– Translate results.

Page 8 of 8

You might also like