You are on page 1of 2

NATIONAL UNIVERSITY OF COMPUTER AND EMERGING SCIENCES

COMPUTER PROGRAMMING CS 104


ASSIGNMENT#4

Submission Date: 2nd Nov, 09

Question 1: Draw the Class diagrams of the following scenarios, in which identify all
the classes, their attributes (data & functionalities) and relationship. Also build skeleton
of all these classes showing relationship among classes as well.

Call Management System:

A call management system is meant to keep information of different calls being made
over PTCL network in Karachi. System keeps information of all PTCL users, their
personal details (NIC No, Name, and Address) and connection details (PTCL No,
Connection Date, Address). A single user can have multiple connections. Call records
include details of call (date, time, duration, calling no, Dialling no.) made over the
network. PTCL provides different calling facilities like CLI, Call Recording, and
Answering machine. PTCL charges a certain amount on each type of facility. System
needs to keep track of which of the services are activated on which connections and their
activation date

E-Commerce Website:

E-malls is a fast emerging concept in the world of e-commerce today. The customer visits
the website and browses over items. If customer wishes to make a purchase he/she has to
create a Shopping Cart. The customer places the Items_To_Purchase in the Shopping
Cart. Every Shopping cart has a unique Id associated with it. It also keeps a count of the
items in the cart. One Customer can have multiple shopping carts, each having multiple
items to purchase. The customer can use only one credit card to make all the payments. A
regular customer is however allowed to use multiple credit cards to make the necessary
payments.

Purchasing a can from a soda machine:

Customer wants to purchase a can of soda. He inserts a coin into the machine‘s coin
receptacle. The machine verifies whether the coin is legitimate, records the amount
deposited then updates the display with the total amount deposited, Customer pushes the
selection button of the type of soda desired. The machine checks whether the desired can
of soda is available or not. If the can is not available, it displays an appropriate message
and asks the customer for another choice. If soda can is available, then machine
calculates whether change is due, and then releases the can of soda and change from its
holding bin, and it drops to the can retrieval. Machine records transaction and then
customer retrieves the can of soda.
NATIONAL UNIVERSITY OF COMPUTER AND EMERGING SCIENCES
COMPUTER PROGRAMMING CS 104
ASSIGNMENT#4

FAST-NU

FAST comprises faculty, staff and students. With new Departments opening up, the
University now caters to CS, CE, TE and BBA courses. CS and CE Departments have
both BS and MS students. The BBA and TE do not provide Master courses however they
provide Bachelors in the respective field. There are some teachers who are Students as
well as part of Faculty. They are called Instructors. The BS students attend university
everyday whereas the Masters students come every Tuesday and Saturday. Some teachers
teach only BS students, others teach both of them. The administration department assigns
the teachers to the courses offered to BS and MS students.

NOTE: You have to submit hard copy of Class Diagrams (hand written is allowed) and
submit the code on khi Forum by the deadline.

You might also like