Class Diagram
Class Diagram
type of static structure diagram that describes the structure of a system by showing
the system's classes, their attributes, operations (or methods), and the relationships
among objects.
A class diagram is used to visualize, describe, and document different aspects of the
system
A description of a group of objects all with similar roles in the system, which consists
of:
Structural features (attributes) define what objects of the class "know"
Behavioral features (operations) define what objects of the class "can do"
Define the way in which objects may interact
Class Notation
1. Class Name
Some of the following rules that should be taken into account while representing
a class are given below:
2. Capitalize the initial letter of the class name.
3. Place the class name in the center of the upper section.
4. A class name must be written in bold format.
Class Attributes
The attributes are written along with its visibility factors, which are public (+),
private (-), protected (#), and package (~).
Operations are shown in the third partition. They are services the class
provides.
Relationships
Dependency: A dependency is a semantic relationship between two or more classes where a
The company encompasses a number of employees, and even if one employee resigns,
the company still exists.
A contact book consists of multiple contacts, and if you delete the contact book, all
the contacts will be lost.
Class Diagram Online ordering System
Class Diagram College management System
Class Diagram Airline Reservation System