+ All Categories
Home > Documents > Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley...

Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley...

Date post: 31-Mar-2015
Category:
Upload: dominic-colleton
View: 246 times
Download: 5 times
Share this document with a friend
28
Slide 1 Systems Analysis and Systems Analysis and Design with UML Version Design with UML Version 2.0, Second Edition 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling John Wiley & Sons, Inc. Copyright 2005
Transcript
Page 1: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 1

Systems Analysis and Systems Analysis and Design with UML Version Design with UML Version 2.0, Second Edition2.0, Second Edition

Alan Dennis, Barbara Haley Wixom, and David Tegarden

Chapter 7: Structural Modeling

John Wiley & Sons, Inc.Copyright 2005

Page 2: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 2

Copyright © 2005John Wiley & Sons, Inc.

All rights reserved. Reproduction or translation of this work beyond that permitted in Section 117 of the 1976 United States Copyright Act without the express written permission of the copyright owner is unlawful. Request for further information should be addressed to the Permissions Department, John Wiley & Sons, Inc. The purchaser may make back-up copies for his/her own use only and not for redistribution or resale. The Publisher assumes no responsibility for errors, omissions, or damages, caused by the use of these programs or from the use of the information contained herein.

Page 3: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 3

Structural Modeling

Chapter 7

Page 4: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 4

Key Ideas

A structural or conceptual model describes the structure of the data that supports the business processes in an organization.The structure of data used in the system is represented through CRD cards, class diagrams, and object diagrams.

Page 5: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 5

STRUCTURAL MODELS

Page 6: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 6

Purpose of Structural Models

Reduce the gap between the real world and the world of softwareCreate a vocabulary for analysts and usersRepresent things, ideas, and concepts of importance in the application domain

Page 7: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 7

Classes

Templates for creating instances or objects

Concrete (Real Class)Abstract (Person, Employee, and Customer)

Typical examples:Application domain, user interface, data structure, file structure, operating environment, document, and multimedia classes

Page 8: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 8

Attributes

Units of information relevant to the description of the classOnly attributes important to the task should be included (Name and color)

Page 9: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 9

Operations

Action that instances/objects can takeFocus on relevant problem-specific operations (at this point)(Select, Add, Delete,and Update)

Page 10: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 10

Relationships

Generalization: Enables inheritance of attributes and operations(person and employee)Aggregation: Relates parts to wholes (car and door)Association: Miscellaneous relationships between classes (patient and schedule)

Page 11: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 11

CLASS-RESPONSIBILITY-COLLABORATION CARDS

Page 12: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 12

Class Responsibilities and Collaborations

ResponsibilitiesKnowingDoing

CollaborationObjects working together to service a request

Page 13: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 13

A CRC Card

Page 14: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 14

Back of CRC Card

Page 15: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 15

CLASS DIAGRAMS

Page 16: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 16

Example Class Diagram

Page 17: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 17

Class Diagram Syntax

A CLASS

AN ATTRIBUTE

AN OPERATION

AN ASSOCIATION

Class 1

-attribute

+operation ()

Attribute name/derived attribute name

operation name ()

1..* 0..1______verb phrase____

Page 18: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 18

More on Attributes

Derived attributes/age, for example can be calculated from birth date and current date

Visibility+ Public# Protected- Private

Page 19: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 19

More on Operations

ConstructorCreates object

QueryMakes information about state available

UpdateChanges values of some or all attributes

Page 20: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 20

Generalization and Aggregation

Generalization shows that a subclass inherits from a superclass

Doctors, nurses, admin personnel are kinds of employees

Aggregation classes comprise other classes

Health team class comprised of doctor, nurses, admin personnel classes

Page 21: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 21

More on Relationships

Class can be related to itself (role)Multiplicity

Exactly one, zero or more, one or more, zero or one, specified range, multiple disjoint ranges

Association class

Page 22: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 22

Simplifying Class Diagrams

Packages show aggregations of classes (or any elements in UML)

Page 23: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 23

Object Diagrams

Page 24: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 24

CREATING CRC CARDS AND CLASS DIAGRAMS

Page 25: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 25

Object Identification

Textual analysis of use-case information

Nouns suggest classesVerbs suggest operations

Page 26: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 26

Steps for Object Identification and Structural Modeling

1. Create CRC cards by performing textual analysis on the use-cases.

2. Brainstorm additional candidate classes, attributes, operations, and relationships by using the common object list approach.

3. Role-play each use-case using the CRC cards.

4. Create the class diagram based on the CRC cards.

5. Review the structural model for missing and/or unnecessary classes, attributes, operations, and relationships.

6. Incorporate useful patterns.

7. Review the structural model.

Page 27: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 27

Summary

CRC cards capture the essential elements of a class.Class and object diagrams show the underlying structure of an object-oriented system.Constructing the structural model is an iterative process involving: textual analysis, brainstorming objects, role playing, creating the diagrams, and incorporating useful patterns.

Page 28: Slide 1 Systems Analysis and Design with UML Version 2.0, Second Edition Alan Dennis, Barbara Haley Wixom, and David Tegarden Chapter 7: Structural Modeling.

Slide 28

Expanding the Domain

A quirky and interesting tutorial regarding CRC cards can be found at:http://www.csc.calpoly.edu/~dbutler/tutorials/winter96/crc_b/


Recommended