Assignment No. 01
Total Marks: 20
Due Date: 10 /11/2016
Please read the following instructions carefully before submitting assignment:
It should be clear that your assignment will not get any credit if:
Note: All types of plagiarism are strictly prohibited.
For any query about the assignment, contact at CS304@vu.edu.pk
The objective of this assignment is:
For any query about the assignment, contact at firstname.lastname@example.org
The galaxy is composed of the stars, satellite and planets etc. In earth’s home galaxy, the solar system is comprised of sun (average star) and objects that orbits around it. Following are the 8 largest objects (planets):
The first four planets are called inner planets while the remaining four are outer planets. All planets revolve around the Sun and Satellites revolve around the planet.
The tasks you have to do are:
Note: You can use any drawing tool such as MS Visio, MS Paint or online drawing tool etc. but you have to paste your diagram in MS Word (.doc) file and submit this file on LMS. Images submitted as solution files will not be accepted.
Lectures Covered: This assignment covers Lecture # 1-6
Deadline: Your assignment must be uploaded/submitted at or before November,10, 2016
Class diagrams are used to represents real life objects in our design by capturing its data methods and relationships of these methods with each other. These classes are basic building blocks of our object oriented system. Class diagrams are represented with white boxes which consist of three parts. Each of these parts has unique characteristics.
The details of these parts are as follow.
Class Diagram Example
OOP: Association, Aggregation, and Composition
Association is a relationship where all objects have their own lifecycle and there is no owner.
Let’s take an example of Teacher and Student. Multiple students can associate with single teacher and single student can associate with multiple teachers, but there is no ownership between the objects and both have their own lifecycle. Both can be created and deleted independently.
Aggregation is a specialized form of Association where all objects have their own lifecycle, but there is ownership and child objects can not belong to another parent object.
Let’s take an example of Department and teacher. A single teacher can not belong to multiple departments, but if we delete the department, the teacher object will not be destroyed. We can think about it as a “has-a” relationship.
Composition is again specialized form of Aggregation and we can call this as a “death” relationship. It is a strong type of Aggregation. Child object does not have its lifecycle and if parent object is deleted, all child objects will also be deleted.
Let’s take again an example of relationship between House and Rooms. House can contain multiple rooms - there is no independent life of room and any room can not belong to two different houses. If we delete the house - room will automatically be deleted.
Let’s take another example relationship between Questions and Options. Single questions can have multiple options and option can not belong to multiple questions. If we delete the questions, options will automatically be deleted.
First read above details and understand class, objects, data members, function, Association, Aggregation, and Composition then read assignment hope so it will much easy for you to understand and draw class diagrams
Wish you all the best
The solution is not according to the questions.
to ap correct diagram bhejen na
i need help
cs304 idea solution
ms word pr paste krna hai like this daigram?????