Professional Documents
Culture Documents
Part 1: Structural Modelling
Part 1: Structural Modelling
Part 1: Structural Modelling
Analysis Modelling II
Part 1: Structural Modelling
Study Outlines
– People
– Places Object
– Things
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Structural Models
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Main aim of structural models to:
Find out the key data contained in the problem domain
Build a structural model of the objects
Structural
Modeling
Solution Domain
Problem Domain
Fig. 1: Structural Modeling [Dennis et al. 2015]
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Classes, Attributes & Operations
• Classes
People instances, places, or things
• Attributes
Features that describe an instance of a class
(an object)
• Operations
Actions or functions that a class can do
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Relationships
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
• Common Object Lists
– Physical things
– Incidents
– Roles
– Interactions
• Patterns
– Collaborating classes that provide solutions to common
problems (groups)
– Developed patterns provide a starting point for work in
similar domains
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Creating CRC Cards
• Index cards used to document the responsibilities
and collaborations of a class
• CRC stand for Class, Responsibilities, Collaborators
• Responsibilities
– Knowing (class attributes)
– Doing—(class operations)
• Collaboration
– Objects working together to service a request (request/reply in Client-
Server)
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Front-Page of CRC Card
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Back-Page of CRC Card
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Role and Benefit of CRC Cards
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Structural Modelling using Class Diagram
• Visibility of an attribute:
– Restricts access to attributes to ensure consistency
– Public attributes (+): visible to all classes
– Private attributes (-): visible only to an instance of the defined class
– Protected attributes (#): visible only to an instance of the class in which
they are defined and its descendants
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Operations
• Common operations are not shown
– Create or delete an instance
– Return or set a value
• Types of Operations:
– Constructor: Creates an object
– Query: Makes information about the state of an object available
– Update: Changes values of some or all of an object’s attributes
– Destructor: Deletes or removes an object
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Relationships
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Multiplicities (Business Rules)
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Association Classes
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Generalization & Aggregation Associations
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Example of Class Diagram (1)
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Example of Class Diagram (2)
Fig. 6: A class diagram for online shopping system, [Kirill Fakhroutdinov, 2019]
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Simplifying Class Diagrams
.Alan Dennis, Barbara Wixom and David Tegarden, System Analysis and Design with UML, 2015, 5th Edition, ISBN: 978-1-119-13826-6
Steps to Structural Models
خطوات النماذج اإلنشائية
• Create CRC Cards
• Incorporate patterns