Lecture 3 - Object Diagrams
Lecture 3 - Object Diagrams
• An Object diagram shows a set of real objects and their links at a given moment
in the system.
• The attributes identified by the class now have values associated with it.
• There might also be behavior associated with the methods (or operations)
identified by the class.
Object Notation
Notation consists of two compartments:
• Anonymous Objects
:className
Examples
Employee
emp1: Employee
-employeeId : int
-employeeName : String employeeId = 001
- address : String employeeName = "Amali"
+ displayEmployeeDetails() : void address = "Maharagama"
Company
Person Contract
- companyId : int
- id : int 1..* - contractId : int 1..*
1..1 1..1 - name : String
- Name : String sign - period : float
has - regNo : String
END