Chapter 15: System Modeling with UML

Slides:



Advertisements
Similar presentations
Object-Oriented Application Development Using VB.NET 1 Chapter 5 Object-Oriented Analysis and Design.
Advertisements

Chapter 22 Object-Oriented Systems Analysis and Design and UML Systems Analysis and Design Kendall and Kendall Fifth Edition.
2008/03/25 Unified Modeling Lanauage 1 Introduction to Unified Modeling Language (UML) – Part One Ku-Yaw Chang Assistant Professor.
Object-Oriented Analysis and Design
Chapter 18 Object-Oriented Systems Analysis and Design Using UML
Systems Analysis and Design in a Changing World, Fourth Edition
Lecture 12: Chapter 22 Topics: UML (Contd.) –Relationship Structural Behavioral –Diagram Structural Behavioral.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 8 Slide 1 System models.
Irwin/McGraw-Hill Copyright © 2004 The McGraw-Hill Companies. All Rights reserved Whitten Bentley DittmanSYSTEMS ANALYSIS AND DESIGN METHODS6th Edition.
Modified from Sommerville’s originalsSoftware Engineering, 7th edition. Chapter 8 Slide 1 System models.
Essentials of interaction diagrams Lecture 23 & 24.
Essentials of interaction diagrams Lecture Outline Collaborations Interaction on collaboration diagrams Sequence diagrams Messages from an object.
© Copyright Eliyahu Brutman Programming Techniques Course.
System Analysis and Design
SE-565 Software System Requirements More UML Diagrams.
Unified Modeling Language
Chapter 7: The Object-Oriented Approach to Requirements
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 7 Slide 1 System models l Abstract descriptions of systems whose requirements are being.
Class, Sequence and UML Model.  Has actors and use cases.
程建群 博士(Dr. Jason Cheng) 年03月
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 7 Slide 1 System models l Abstract descriptions of systems whose requirements are being.
Chapter 4 System Models A description of the various models that can be used to specify software systems.
System models Abstract descriptions of systems whose requirements are being analysed Abstract descriptions of systems whose requirements are being analysed.
System Modelling with UML objectives
Copyright 2002 Prentice-Hall, Inc. Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich Chapter 20 Object-Oriented.
5 Systems Analysis and Design in a Changing World, Fourth Edition.
©Ian Sommerville 1995/2000 (Modified by Spiros Mancoridis 1999) Software Engineering, 6th edition. Chapter 7 Slide 1 System models l Abstract descriptions.
Programming in Java Unit 3. Learning outcome:  LO2:Be able to design Java solutions  LO3:Be able to implement Java solutions Assessment criteria: 
Copyright 2002 Prentice-Hall, Inc. Chapter 2 Object-Oriented Analysis and Design Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey.
Chapter 7 System models.
Modified by Juan M. Gomez Software Engineering, 6th edition. Chapter 7 Slide 1 Chapter 7 System Models.
Systems Analysis and Design in a Changing World, 3rd Edition
Software Engineering, 8th edition Chapter 8 1 Courtesy: ©Ian Somerville 2006 April 06 th, 2009 Lecture # 13 System models.
Sommerville 2004,Mejia-Alvarez 2009Software Engineering, 7th edition. Chapter 8 Slide 1 System models.
Chapter 5 Models and UML Notation for The Object-Oriented Approach.
Systems Analysis & Design 7 th Edition Chapter 5.
Programming Logic and Design Fourth Edition, Comprehensive Chapter 15 System Modeling with the UML.
ניתוח מערכות מידע 1 Unified Modeling Language (UML) § § The Unified Modeling Language (UML) is the industry-standard language for: Specifying, Visualizing,
9-1 © Prentice Hall, 2004 Chapter 9: Analysis Classes Object-Oriented Systems Analysis and Design Joey F. George, Dinesh Batra, Joseph S. Valacich, Jeffrey.
9-1 © Prentice Hall, 2007 Chapter 9: Analysis Classes Object-Oriented Systems Analysis and Design Joey F. George, Dinesh Batra, Joseph S. Valacich, Jeffrey.
TAL7011 – Lecture 4 UML for Architecture Modeling.
Design Jon Walker. More UML ● What is UML again?
Introduction to UML CS A470. What is UML? Unified Modeling Language –OMG Standard, Object Management Group –Based on work from Booch, Rumbaugh, Jacobson.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 8 Slide 1 System models.
Systems Analysis and Design in a Changing World, Fourth Edition
Lecture 9-1 : Intro. to UML (Unified Modeling Language)
1 Technical & Business Writing (ENG-715) Muhammad Bilal Bashir UIIT, Rawalpindi.
INFO 620Lecture #71 Information Systems Analysis and Design Design Class Diagrams and others INFO 620 Glenn Booker.
7-1 © Prentice Hall, 2007 Topic 7: Analysis Classes Object-Oriented Systems Analysis and Design Joey F. George, Dinesh Batra, Joseph S. Valacich, Jeffrey.
Object-Oriented Application Development Using VB.NET 1 Chapter 5 Object-Oriented Analysis and Design.
Chapter 3: Introducing the UML
 To explain why the context of a system should be modelled as part of the RE process  To describe behavioural modelling, data modelling and object modelling.
Object Oriented Analysis and Design Introduction to Rational Rose.
Technical Module C Object Modeling Objects Object – a valuable resource: Money (Account Receivable) Material (Product) Machines (Delivery Truck) Personnel.
Diagrams. Typically, we view the static parts of a system using one of the four following diagrams. 1. Class diagram 2. Object diagram 3. Component diagram.
7 Systems Analysis – ITEC 3155 The Object Oriented Approach – Use Cases.
1 7 Systems Analysis and Design in a Changing World, 2 nd Edition, Satzinger, Jackson, & Burd Chapter 7 The Object-Oriented Approach to Requirements.
WELCOME TO OUR PRESENTATION UNIFIED MODELING LANGUAGE (UML)
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 8 Slide 1 System models.
Engineering, 7th edition. Chapter 8 Slide 1 System models.
Data Modeling Using the Entity- Relationship (ER) Model
Systems Analysis and Design in a Changing World, Fourth Edition
Analysis Classes Unit 5.
UML Diagrams By Daniel Damaris Novarianto S..
Unified Modeling Language
Unified Modeling Language
Systems Analysis and Design With UML 2
Week 12: Activity & Sequence Diagrams
Chapter 5.
Chapter 22 Object-Oriented Systems Analysis and Design and UML
Presentation transcript:

Chapter 15: System Modeling with UML Programming Logic and Design, Third Edition Comprehensive

Programming Logic and Design, Third Edition Comprehensive Objectives After studying Chapter 15, you should be able to: Understand the need for system modeling Describe the UML Work with use case diagrams Use class and object diagrams Use sequence and collaboration diagrams Programming Logic and Design, Third Edition Comprehensive

Objectives (continued) Use statechart diagrams Use activity diagrams Use component and deployment diagrams Decide which UML diagrams to use Programming Logic and Design, Third Edition Comprehensive

Understanding the Need for System Modeling Computer programs often stand alone to solve a user’s specific problem Producing a set of programs that operate together correctly requires careful planning System design: detailed specification of how all the parts of a system will be implemented and coordinated Programming Logic and Design, Third Edition Comprehensive

Understanding the Need for System Modeling (continued) Some basic principles: Large systems are easier to understand when you break them down into subsystems Good modeling techniques are increasingly important as the size and complexity of systems increase Good models promote communication among technical and non-technical workers while ensuring good business solutions Programming Logic and Design, Third Edition Comprehensive

Programming Logic and Design, Third Edition Comprehensive What Is UML? Unified Modeling Language Standard way to specify, construct, and document systems that use object-oriented methods Modeling language, not a programming language Provides nine different diagram types that you can use to model systems Programming Logic and Design, Third Edition Comprehensive

What Is UML? (continued) Each of the diagram types lets you see a business process from a different angle, and appeals to a different type of user The nine UML diagram types are: Use case diagrams – Class diagrams Object diagrams – Sequence diagrams Collaboration diagrams – Statechart diagrams Activity diagrams – Component diagrams Deployment diagrams Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams shows how a business works from the perspective of those who approach it from the outside, or those who actually use the business Many types of users—for example, employees, customers, and suppliers Use cases do not necessarily represent all the functions of a system Are the system functions or services that are visible to the system’s actors Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams (continued) Figure 15-1 shows a use case diagram for these two events Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams (continued) In many systems, there are variations in use cases The three possible types of variations are: Extend: Shows functions beyond those found in a base case For example, checking out a book for a new library patron who doesn’t have a library card is slightly more complicated then checking out a book for an existing patron Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams (continued) Each variation in the sequence of actions required in a use case is a scenario Extended use cases are shown in an oval with a dashed arrow pointing to the more general base case Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams (continued) For clarity, add “<<extend>>” near line that shows relationship extension Stereotype: Adds to UML vocabulary of shapes to make them more meaningful for the reader Figure 15-3 includes a stereotype Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams (continued) 2. Include Use when a case can be part of multiple use cases Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams (continued) Use a generalization when a use case is less specific than others you want to be able to substitute the more specific case for a general one Figure 15-5 shows the generalization acquireNewItem() with two more specific situations: acquiring videos and CDs The more specific scenarios are attached to the general scenario with open-headed dashed arrows Programming Logic and Design, Third Edition Comprehensive

Use Case Diagram for Librarian, with Generalization Programming Logic and Design, Third Edition Comprehensive

Using Use Case Diagrams (continued) A use case diagram is only a tool to aid communication No single “correct” use case diagram exists; you might correctly represent a system in several ways For example, you might choose to emphasize the actors in the library system, as shown in Figure 15-7, or to emphasize system requirements, as shown in Figure 15-8 Programming Logic and Design, Third Edition Comprehensive

Use Case Diagram Emphasizing Actors Programming Logic and Design, Third Edition Comprehensive

Use Case Diagram Emphasizing System Requirements Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams You use a class diagram to illustrate the names, attributes, and methods of a class or set of classes More useful to system’s programmers than to users because they closely resemble code the programmers will write Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams (continued) A class diagram illustrating a single class contains a rectangle divided into three sections (Figure 15-9) the top section contains the name of the class the middle section contains the name of the attributes the bottom section contains the names of the methods Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams (continued) Class diagrams can include symbols that show the relationships between objects You can show two types of relationships: An association relationship A whole-part relationship Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams (continued) Association relationship: Describes the connection or link between objects Represented by a straight line Frequently, you include information about the arithmetical relationship or ratio (called cardinality or multiplicity) of the objects For example, Figure 15-11 shows the association relationship between a Library and the LibraryItems it lends Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams (continued) Figure 15-12 adds the Patron class to the diagram and shows how you indicate that any number of Patrons can be associated with the Library, but that each Patron can borrow only up to five LibraryItems at a time, or currently might not be borrowing any In addition, each LibraryItem can be associated with at most one Patron, but at any given time might not be on loan Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams (continued) Programming Logic and Design, Third Edition Comprehensive

Class Diagram with Several Association Relationships Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams (continued) Whole-part relationship: describes an association in which one or more classes make up the parts of a larger whole class For example, 50 states “make up” the United States, and 10 departments might “make up” a company Also called an aggregation Represented by an open diamond at the “whole part” end of the line that indicates the relationship Programming Logic and Design, Third Edition Comprehensive

Class Diagram with Whole-Part Relationship Programming Logic and Design, Third Edition Comprehensive

Using Class and Object Diagrams (continued) You also can call a whole-part relationship a has-a relationship Figure 15-13 shows a whole-part relationship for a Library Object diagrams are similar to class diagrams, but they model specific instances of classes Use to show a snapshot of an object at one point in time, so you can more easily understand its relationship to other objects Programming Logic and Design, Third Edition Comprehensive

Object Diagram for Library Programming Logic and Design, Third Edition Comprehensive

Using Sequence and Collaboration Diagrams Use a sequence diagram to show the timing of events in a single use case makes it easier to see the order in which activities occur The horizontal axis (x-axis) of a sequence diagram represents objects The vertical axis (y-axis) represents time For example, Figure 15-15 shows a sequence diagram for a scenario that a librarian can use to create a book checkout record Programming Logic and Design, Third Edition Comprehensive

Using Sequence and Collaboration Diagrams (continued) A collaboration diagram emphasizes the organization of objects that participate in a system contains sequence numbers to represent the precise order in which activities occur Figure 15-16 shows the same sequence of events as Figure 15-15, but the steps to creating a BookCheckOutRecord are clearly numbered Programming Logic and Design, Third Edition Comprehensive

Sequence Diagram for Checking Out a Book for a Patron Programming Logic and Design, Third Edition Comprehensive

Collaboration Diagram for Checking Out a Book for a Patron Programming Logic and Design, Third Edition Comprehensive

Using Statechart Diagrams shows the different status of a class or object at different points in time Use to illustrate aspects of a system that show interesting changes in behavior as time passes Figure 15-17 contains a statechart diagram you can use to describe the states of a Book Programming Logic and Design, Third Edition Comprehensive

Statechart Diagram for Book Class Programming Logic and Design, Third Edition Comprehensive

Using Activity Diagrams The UML diagram that most closely resembles a conventional flowchart is an activity diagram: shows the flow of actions of a system, including branches that occur when decisions affect the outcome use flowchart start and stop symbols (called lozenges) to describe actions Use solid dots to represent start and stop states Programming Logic and Design, Third Edition Comprehensive

Using Activity Diagrams (continued) Like flowcharts, activity diagrams use diamonds to describe decisions Unlike the diamonds in flowcharts, the diamonds in UML activity diagrams usually are empty possible outcomes are documented along the branches emerging from the decision symbol Figure 15-18 shows a simple activity diagram with a single branch Programming Logic and Design, Third Edition Comprehensive

Activity Diagram Showing Branch Programming Logic and Design, Third Edition Comprehensive

Using Component and Deployment Diagrams Component and deployment diagrams model the physical aspects of systems Component diagram: Use to emphasize files, database tables, documents, and other components that a system’s software uses Deployment diagram: Use to focus on a system’s hardware Programming Logic and Design, Third Edition Comprehensive

Using Component and Deployment Diagrams You can use a variety of icons in each type of diagram, but each icon must convey meaning to the reader Figures 15-20 and 15-21 shows component and deployment diagrams that illustrate aspects of a library system Programming Logic and Design, Third Edition Comprehensive

Programming Logic and Design, Third Edition Comprehensive Component Diagram Programming Logic and Design, Third Edition Comprehensive

Programming Logic and Design, Third Edition Comprehensive Deployment Diagram Programming Logic and Design, Third Edition Comprehensive

Deciding Which UML Diagrams to Use Each of the nine UML diagram types provides a different view of a system Just as a portrait artist, psychologist, and neurosurgeon each prefer a different conceptual view of your head, the users, managers, designers, and technicians of computer and business systems each prefer specific system views Programming Logic and Design, Third Edition Comprehensive

Programming Logic and Design, Third Edition Comprehensive Summary System design is the detailed specification of how all the parts of a system will be implemented and coordinated A use case diagram shows how a business works from the perspective of those who approach it from the outside, or those who actually use the business You use a class diagram to illustrate the names, attributes, and method of a class or set of classes Programming Logic and Design, Third Edition Comprehensive

Programming Logic and Design, Third Edition Comprehensive Summary (continued) You use a sequence diagram to show the timing of events in a single use case A statechart diagram shows the different status of a class or object at different points in time You use a component diagram when you want to emphasize the files, database tables, documents, and other components that a system’s software uses Programming Logic and Design, Third Edition Comprehensive