2,086
28
Research Paper, 2 pages (250 words)

Draw class diagram for the situation

Diagrams According to Ambler, diagrams describe the static structure of a system and are the backbone for almost all object- oriented methods. An abstraction of entities with common characteristics is represented by classes while the relationships between classes are represented by associations.(2005) In class diagrams, classes are represented by rectangles divided into three compartments with the first partition indicating the class name, the class attributes on the second partition and finally the class methods (operations) on the last partition.(Ambler, 2005) The class attributes and operations have visibility which shows access type of the information contained in them. Visibility can be private, public or protected.
In Jim Smith’s dealership situation as presented, there are four classes involved: Manufacturer, Car, Buyer and Contact information. Each class has its own attributes, the car manufacturer has both name and contact information as its attributes, the car has list price, buying price, model name and model series, the buyer has a name, car bought, buying price and address and finally contact information with both address and phone number as attributes. All the attributes of all the classes should be private hence the negative sign before the attributes. Association between the classes is an important part of class diagrams and is as follows according to the situation presented in Jim Smith’s dealership: A car manufacturer can sell one or many cars to the dealership, a buyer can buy one or many cars from the dealership, a buy lives at one specific address.
Class diagram

1..*
Sells
Lives at
CONTACT INFORMATION
-Address
-Phone Number
+Update(): Void
+Output As Label(): String

Work Cited
Ambler, Scott W. The elements of UML 2. 0 style. Cambridge [U. K.: Cambridge University
Press, 2005. Print.
Top of Form
Bottom of Form

Thank's for Your Vote!
Draw class diagram for the situation. Page 1
Draw class diagram for the situation. Page 2
Draw class diagram for the situation. Page 3

This work, titled "Draw class diagram for the situation" was written and willingly shared by a fellow student. This sample can be utilized as a research and reference resource to aid in the writing of your own work. Any use of the work that does not include an appropriate citation is banned.

If you are the owner of this work and don’t want it to be published on AssignBuster, request its removal.

Request Removal
Cite this Research Paper

References

AssignBuster. (2021) 'Draw class diagram for the situation'. 17 November.

Reference

AssignBuster. (2021, November 17). Draw class diagram for the situation. Retrieved from https://assignbuster.com/draw-class-diagram-for-the-situation/

References

AssignBuster. 2021. "Draw class diagram for the situation." November 17, 2021. https://assignbuster.com/draw-class-diagram-for-the-situation/.

1. AssignBuster. "Draw class diagram for the situation." November 17, 2021. https://assignbuster.com/draw-class-diagram-for-the-situation/.


Bibliography


AssignBuster. "Draw class diagram for the situation." November 17, 2021. https://assignbuster.com/draw-class-diagram-for-the-situation/.

Work Cited

"Draw class diagram for the situation." AssignBuster, 17 Nov. 2021, assignbuster.com/draw-class-diagram-for-the-situation/.

Get in Touch

Please, let us know if you have any ideas on improving Draw class diagram for the situation, or our service. We will be happy to hear what you think: [email protected]