SlideShare a Scribd company logo
TOPIC:UML CLASS DIAGRAM NOTATION
17BS(IT)63
1
Shaheed Benazir Bhutto
University
Shaheed Benazir Abad
Name: Adnan Ejaz
Roll No: 17BSIT(063) Present to: ABC……
What is a Class Diagram?
 A Class Diagram is a diagram describing the structure of a system
 • shows the system's
 • classes
 • Attributes
 • operations (or methods),
 • Relationships among the classes.
17BS(IT)63
2
Essential Elements of a UML Class
Diagram
 Class
 Attributes
 Operations
 Relationships
 Associations
 Generalization
 Realization
17BS(IT)63
3
Class
 Describes a set of objects having similar:
 – Attributes (status)
 – Operations (behavior) Class Name Window
 – Relationships with other classes
 • Attributes and operations may Attributes size: Size visibility:
 – have their visibility marked: visibility: boolean
 Operations display() hide()
17BS(IT)63
4
Associations
 An association between two classes indicates that objects at one end of
an association “recognize” objects at the other end and may send
messages to them.
 • Example: “An Employee works for a Company”
 Employee Company
17BS(IT)63
5
Associations (cont.)
StaffMember Student
1..* *instructs
instructor
Association
name
Role
name
Multiplicity
Navigable
(uni-directional)
association
Courses
pre -
requisites
0..3
Reflexive
association
Role
*
17BS(IT)63
6
Associations (cont.)
 To clarify its meaning, an association may be named.
 The name is represented as a label placed midway along the association line.
 Usually a verb or a verb phrase.
 A role is an end of an association where it connects to a class.
 May be named to indicate the role played by the class attached to the end of
the association path.
 Usually a noun or noun phrase
17BS(IT)63
7
Associations (cont.)
 Mandatory for reflexive associations
 Multiplicity
 the number of objects that participate in the association.
 Indicates whether or not an association is mandatory.
 Multiplicity Indicators
 Exactly one 1
 Zero or more (unlimited)* (0..*)
 One or more 1..*
 Zero or one (optional association) 0..1
 Specified range 2..4
 Multiple, disjoint ranges 2, 4..6, 8
17BS(IT)63
8
Aggregation
 A special form of association that models a whole-part relationship between an aggregate (the
whole) and its parts.
 – Models a “is a part-part of” relationship.
Whole Part
Car Door House
1..*2..*
17BS(IT)63
9
Aggregation (cont.)
 Aggregation tests:
 – Is the phrase “part of” used to describe the relationship?
 A door is “part of” a car
 Are some operations on the whole automatically applied to its parts?
 Move the car, move the door.
 Are some attribute values propagated from the whole to all or some of its parts?
 The car is blue, therefore the door is blue.
 Is there an intrinsic asymmetry to the relationship where one class is subordinate
to the other?
 A door is part of a car. A car is not part of a door.
17BS(IT)63
10
Generalization
 Indicates that objects of the specialized class (subclass) are substitutable for objects of the
generalized class (super-class).
 – “is kind of” relationship.
Shape
}abstract{
Circle
Super
Class
Sub
Class
An abstract
class
Generalization
relationship
17BS(IT)63
11
Generalization
 A sub-class inherits from its super-class
 Attributes
 Operations
 Relationships
 A sub-class may
 Add attributes and operations
 Add relationships
 Refine (override) inherited operations
 A generalization relationship may not be used to model interface implementation.
17BS(IT)63
12
Realization
 A realization relationship indicates that one class implements a behavior
specified by another class (an interface or protocol).
 An interface can be realized by many classes.
 A class may realize many interfaces.
LinkedList
<<interface>>
List
17BS(IT)63
13
THANK YOU
17BS(IT)63
14
Ad

More Related Content

What's hot (20)

Uml class Diagram
Uml class DiagramUml class Diagram
Uml class Diagram
Satyamevjayte Haxor
 
Object diagram
Object diagramObject diagram
Object diagram
Rahul Pola
 
Class diagrams
Class diagramsClass diagrams
Class diagrams
Nadia_Nazeer
 
10 component diagram
10 component diagram10 component diagram
10 component diagram
Baskarkncet
 
Activity diagrams
Activity diagramsActivity diagrams
Activity diagrams
Jalaxy Jahury
 
Class diagram
Class diagramClass diagram
Class diagram
SESP123
 
Architectural Modeling
Architectural ModelingArchitectural Modeling
Architectural Modeling
AMITJain879
 
Uml deployment diagram
Uml deployment diagramUml deployment diagram
Uml deployment diagram
Asraa Batool
 
Architectural modeling chapter 5 of omd
Architectural modeling chapter 5 of omdArchitectural modeling chapter 5 of omd
Architectural modeling chapter 5 of omd
jayashri kolekar
 
UNIFIED MODELING LANGUAGE
UNIFIED MODELING LANGUAGEUNIFIED MODELING LANGUAGE
UNIFIED MODELING LANGUAGE
Raval Chirag
 
The Ultimate Sequence Diagram Tutorial
The Ultimate Sequence Diagram TutorialThe Ultimate Sequence Diagram Tutorial
The Ultimate Sequence Diagram Tutorial
Creately
 
Activity diagram
Activity diagramActivity diagram
Activity diagram
bhupendra kumar
 
Component Diagram
Component DiagramComponent Diagram
Component Diagram
Manas Shukla
 
Lecture6 activity diagrams
Lecture6 activity diagramsLecture6 activity diagrams
Lecture6 activity diagrams
Shahid Riaz
 
Uml Activity Diagram
Uml Activity DiagramUml Activity Diagram
Uml Activity Diagram
Niloy Rocker
 
Uml class-diagram
Uml class-diagramUml class-diagram
Uml class-diagram
ASHOK KUMAR PALAKI
 
Sequence diagrams
Sequence diagramsSequence diagrams
Sequence diagrams
Vince Carter
 
Package Diagram
Package DiagramPackage Diagram
Package Diagram
WASI ALI
 
Component diagram
Component diagramComponent diagram
Component diagram
Abdul Manan
 
Domain Modeling
Domain ModelingDomain Modeling
Domain Modeling
Harsh Jegadeesan
 
Object diagram
Object diagramObject diagram
Object diagram
Rahul Pola
 
10 component diagram
10 component diagram10 component diagram
10 component diagram
Baskarkncet
 
Class diagram
Class diagramClass diagram
Class diagram
SESP123
 
Architectural Modeling
Architectural ModelingArchitectural Modeling
Architectural Modeling
AMITJain879
 
Uml deployment diagram
Uml deployment diagramUml deployment diagram
Uml deployment diagram
Asraa Batool
 
Architectural modeling chapter 5 of omd
Architectural modeling chapter 5 of omdArchitectural modeling chapter 5 of omd
Architectural modeling chapter 5 of omd
jayashri kolekar
 
UNIFIED MODELING LANGUAGE
UNIFIED MODELING LANGUAGEUNIFIED MODELING LANGUAGE
UNIFIED MODELING LANGUAGE
Raval Chirag
 
The Ultimate Sequence Diagram Tutorial
The Ultimate Sequence Diagram TutorialThe Ultimate Sequence Diagram Tutorial
The Ultimate Sequence Diagram Tutorial
Creately
 
Lecture6 activity diagrams
Lecture6 activity diagramsLecture6 activity diagrams
Lecture6 activity diagrams
Shahid Riaz
 
Uml Activity Diagram
Uml Activity DiagramUml Activity Diagram
Uml Activity Diagram
Niloy Rocker
 
Package Diagram
Package DiagramPackage Diagram
Package Diagram
WASI ALI
 
Component diagram
Component diagramComponent diagram
Component diagram
Abdul Manan
 

Similar to UML Class Diagram Notation (20)

Descriptions of class diagrams in software
Descriptions of class diagrams in softwareDescriptions of class diagrams in software
Descriptions of class diagrams in software
ssuser9d62d6
 
Object and class relationships
Object and class relationshipsObject and class relationships
Object and class relationships
Pooja mittal
 
Selab1 slides
Selab1 slidesSelab1 slides
Selab1 slides
Sumedha
 
uml2-1214558329929112-8.ppt
uml2-1214558329929112-8.pptuml2-1214558329929112-8.ppt
uml2-1214558329929112-8.ppt
AleksandarUrdarevski
 
Css uml
Css umlCss uml
Css uml
suman Aggarwal
 
M04_DesignPatterns software engineering.ppt
M04_DesignPatterns software engineering.pptM04_DesignPatterns software engineering.ppt
M04_DesignPatterns software engineering.ppt
ssuser2d043c
 
Uml - An Overview
Uml - An OverviewUml - An Overview
Uml - An Overview
Raj Thilak S
 
08 class and sequence diagrams
08   class and sequence diagrams08   class and sequence diagrams
08 class and sequence diagrams
kebsterz
 
Unified Modelling Language
Unified Modelling Language Unified Modelling Language
Unified Modelling Language
TRAN Khanh Dung, Khoa CNTT, Đại Học Xây Dựng
 
Umldiagram
UmldiagramUmldiagram
Umldiagram
pavandeep11
 
Architecture and design
Architecture and designArchitecture and design
Architecture and design
himanshu_airon
 
Slides chapter 11
Slides chapter 11Slides chapter 11
Slides chapter 11
Priyanka Shetty
 
Object-oriented modeling and design.pdf
Object-oriented modeling and  design.pdfObject-oriented modeling and  design.pdf
Object-oriented modeling and design.pdf
SHIVAM691605
 
UML, ER and Dimensional Modelling
UML, ER and Dimensional ModellingUML, ER and Dimensional Modelling
UML, ER and Dimensional Modelling
Stefano Dalla Palma
 
Uml unified-modeling-language-presented by dileep
Uml unified-modeling-language-presented by dileepUml unified-modeling-language-presented by dileep
Uml unified-modeling-language-presented by dileep
mekhap
 
4. UML
4. UML4. UML
4. UML
Ashis Kumar Chanda
 
ASP.NET System design 2
ASP.NET System design 2ASP.NET System design 2
ASP.NET System design 2
Sisir Ghosh
 
Software Testing and UML Lab
Software Testing and UML LabSoftware Testing and UML Lab
Software Testing and UML Lab
Harsh Kishore Mishra
 
Intro Uml
Intro UmlIntro Uml
Intro Uml
Kris der Rose
 
Object Oriented Modeling and Design with UML
Object Oriented Modeling and Design with UMLObject Oriented Modeling and Design with UML
Object Oriented Modeling and Design with UML
Malek Sumaiya
 
Descriptions of class diagrams in software
Descriptions of class diagrams in softwareDescriptions of class diagrams in software
Descriptions of class diagrams in software
ssuser9d62d6
 
Object and class relationships
Object and class relationshipsObject and class relationships
Object and class relationships
Pooja mittal
 
Selab1 slides
Selab1 slidesSelab1 slides
Selab1 slides
Sumedha
 
M04_DesignPatterns software engineering.ppt
M04_DesignPatterns software engineering.pptM04_DesignPatterns software engineering.ppt
M04_DesignPatterns software engineering.ppt
ssuser2d043c
 
08 class and sequence diagrams
08   class and sequence diagrams08   class and sequence diagrams
08 class and sequence diagrams
kebsterz
 
Architecture and design
Architecture and designArchitecture and design
Architecture and design
himanshu_airon
 
Object-oriented modeling and design.pdf
Object-oriented modeling and  design.pdfObject-oriented modeling and  design.pdf
Object-oriented modeling and design.pdf
SHIVAM691605
 
UML, ER and Dimensional Modelling
UML, ER and Dimensional ModellingUML, ER and Dimensional Modelling
UML, ER and Dimensional Modelling
Stefano Dalla Palma
 
Uml unified-modeling-language-presented by dileep
Uml unified-modeling-language-presented by dileepUml unified-modeling-language-presented by dileep
Uml unified-modeling-language-presented by dileep
mekhap
 
ASP.NET System design 2
ASP.NET System design 2ASP.NET System design 2
ASP.NET System design 2
Sisir Ghosh
 
Object Oriented Modeling and Design with UML
Object Oriented Modeling and Design with UMLObject Oriented Modeling and Design with UML
Object Oriented Modeling and Design with UML
Malek Sumaiya
 
Ad

Recently uploaded (20)

ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes
 
Quantum Computing Quick Research Guide by Arthur Morgan
Quantum Computing Quick Research Guide by Arthur MorganQuantum Computing Quick Research Guide by Arthur Morgan
Quantum Computing Quick Research Guide by Arthur Morgan
Arthur Morgan
 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
 
Big Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur MorganBig Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur Morgan
Arthur Morgan
 
How analogue intelligence complements AI
How analogue intelligence complements AIHow analogue intelligence complements AI
How analogue intelligence complements AI
Paul Rowe
 
Cybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure ADCybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure AD
VICTOR MAESTRE RAMIREZ
 
Linux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded DevelopersLinux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded Developers
Toradex
 
HCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser EnvironmentsHCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser Environments
panagenda
 
Heap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and DeletionHeap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and Deletion
Jaydeep Kale
 
What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...
Vishnu Singh Chundawat
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
Drupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy ConsumptionDrupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy Consumption
Exove
 
Rusty Waters: Elevating Lakehouses Beyond Spark
Rusty Waters: Elevating Lakehouses Beyond SparkRusty Waters: Elevating Lakehouses Beyond Spark
Rusty Waters: Elevating Lakehouses Beyond Spark
carlyakerly1
 
Role of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered ManufacturingRole of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered Manufacturing
Andrew Leo
 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
 
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
BookNet Canada
 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
 
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes
 
Quantum Computing Quick Research Guide by Arthur Morgan
Quantum Computing Quick Research Guide by Arthur MorganQuantum Computing Quick Research Guide by Arthur Morgan
Quantum Computing Quick Research Guide by Arthur Morgan
Arthur Morgan
 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
 
Big Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur MorganBig Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur Morgan
Arthur Morgan
 
How analogue intelligence complements AI
How analogue intelligence complements AIHow analogue intelligence complements AI
How analogue intelligence complements AI
Paul Rowe
 
Cybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure ADCybersecurity Identity and Access Solutions using Azure AD
Cybersecurity Identity and Access Solutions using Azure AD
VICTOR MAESTRE RAMIREZ
 
Linux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded DevelopersLinux Support for SMARC: How Toradex Empowers Embedded Developers
Linux Support for SMARC: How Toradex Empowers Embedded Developers
Toradex
 
HCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser EnvironmentsHCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser Environments
panagenda
 
Heap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and DeletionHeap, Types of Heap, Insertion and Deletion
Heap, Types of Heap, Insertion and Deletion
Jaydeep Kale
 
What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...
Vishnu Singh Chundawat
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
Drupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy ConsumptionDrupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy Consumption
Exove
 
Rusty Waters: Elevating Lakehouses Beyond Spark
Rusty Waters: Elevating Lakehouses Beyond SparkRusty Waters: Elevating Lakehouses Beyond Spark
Rusty Waters: Elevating Lakehouses Beyond Spark
carlyakerly1
 
Role of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered ManufacturingRole of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered Manufacturing
Andrew Leo
 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
 
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
BookNet Canada
 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
 
Ad

UML Class Diagram Notation

  • 1. TOPIC:UML CLASS DIAGRAM NOTATION 17BS(IT)63 1 Shaheed Benazir Bhutto University Shaheed Benazir Abad Name: Adnan Ejaz Roll No: 17BSIT(063) Present to: ABC……
  • 2. What is a Class Diagram?  A Class Diagram is a diagram describing the structure of a system  • shows the system's  • classes  • Attributes  • operations (or methods),  • Relationships among the classes. 17BS(IT)63 2
  • 3. Essential Elements of a UML Class Diagram  Class  Attributes  Operations  Relationships  Associations  Generalization  Realization 17BS(IT)63 3
  • 4. Class  Describes a set of objects having similar:  – Attributes (status)  – Operations (behavior) Class Name Window  – Relationships with other classes  • Attributes and operations may Attributes size: Size visibility:  – have their visibility marked: visibility: boolean  Operations display() hide() 17BS(IT)63 4
  • 5. Associations  An association between two classes indicates that objects at one end of an association “recognize” objects at the other end and may send messages to them.  • Example: “An Employee works for a Company”  Employee Company 17BS(IT)63 5
  • 6. Associations (cont.) StaffMember Student 1..* *instructs instructor Association name Role name Multiplicity Navigable (uni-directional) association Courses pre - requisites 0..3 Reflexive association Role * 17BS(IT)63 6
  • 7. Associations (cont.)  To clarify its meaning, an association may be named.  The name is represented as a label placed midway along the association line.  Usually a verb or a verb phrase.  A role is an end of an association where it connects to a class.  May be named to indicate the role played by the class attached to the end of the association path.  Usually a noun or noun phrase 17BS(IT)63 7
  • 8. Associations (cont.)  Mandatory for reflexive associations  Multiplicity  the number of objects that participate in the association.  Indicates whether or not an association is mandatory.  Multiplicity Indicators  Exactly one 1  Zero or more (unlimited)* (0..*)  One or more 1..*  Zero or one (optional association) 0..1  Specified range 2..4  Multiple, disjoint ranges 2, 4..6, 8 17BS(IT)63 8
  • 9. Aggregation  A special form of association that models a whole-part relationship between an aggregate (the whole) and its parts.  – Models a “is a part-part of” relationship. Whole Part Car Door House 1..*2..* 17BS(IT)63 9
  • 10. Aggregation (cont.)  Aggregation tests:  – Is the phrase “part of” used to describe the relationship?  A door is “part of” a car  Are some operations on the whole automatically applied to its parts?  Move the car, move the door.  Are some attribute values propagated from the whole to all or some of its parts?  The car is blue, therefore the door is blue.  Is there an intrinsic asymmetry to the relationship where one class is subordinate to the other?  A door is part of a car. A car is not part of a door. 17BS(IT)63 10
  • 11. Generalization  Indicates that objects of the specialized class (subclass) are substitutable for objects of the generalized class (super-class).  – “is kind of” relationship. Shape }abstract{ Circle Super Class Sub Class An abstract class Generalization relationship 17BS(IT)63 11
  • 12. Generalization  A sub-class inherits from its super-class  Attributes  Operations  Relationships  A sub-class may  Add attributes and operations  Add relationships  Refine (override) inherited operations  A generalization relationship may not be used to model interface implementation. 17BS(IT)63 12
  • 13. Realization  A realization relationship indicates that one class implements a behavior specified by another class (an interface or protocol).  An interface can be realized by many classes.  A class may realize many interfaces. LinkedList <<interface>> List 17BS(IT)63 13