Interaction Diagrams CS 124. Object collaboration A use case carried out involves objects and interaction or collaboration between these objects Method.

Slides:



Advertisements
Similar presentations
System Sequence Diagrams
Advertisements

Use Cases and Object Interaction CS 123/CS 231. Depicting System Behavior zFirst, identify the use cases ÕUse case: typical interaction between a user.
Interaction Diagram Notation From Chapter 15 of Craig Larman, Applying UML and Patterns John Dalesandro.
UML (Sequence Diagrams, Collaboration and State Chart Diagrams) Presentation By - SANDEEP REDDY CHEEDEPUDI (Student No: ) - VISHNU CHANDRADAS (Student.
UML Class and Sequence Diagrams Violet Slides adapted from Marty Stepp, CSE 403, Winter 2012 CSE 403 Spring 2012 Anton Osobov.
Assess A Claim Object Interaction Diagrams. Object sequence Diagrams - Use case Sequence of events that occur during one particular execution of a system.
Software Engineering COMP 201
Drawing System Sequence Diagrams
Systems Analysis and Design in a Changing World, Fourth Edition
Practical Object-Oriented Design with UML 2e Slide 1/1 ©The McGraw-Hill Companies, 2004 PRACTICAL OBJECT-ORIENTED DESIGN WITH UML 2e Chapter 5: Restaurant.
Design Patterns in Java Appendix D UML at a Glance Summary prepared by Kirk Scott 1.
THE OBJECT-ORIENTED DESIGN WORKFLOW UML2 Sequence Diagrams.
1 © Wolfgang Pelz UML2 UML Part Two. 2 © Wolfgang Pelz UML2 Chapters Four & Twelve Interaction Diagrams.
Essentials of interaction diagrams Lecture 23 & 24.
Essentials of interaction diagrams Lecture Outline Collaborations Interaction on collaboration diagrams Sequence diagrams Messages from an object.
Object Collaborations. Objectives: Object Interaction (cont.) You will be able to:  Use sequence diagrams to detail object interactions.
Lab 6 CPIT 250 System Analysis and Design.
Sequence Diagrams By Zvika Gutterman Adam Carmi. Sequence Diagrams2 Agenda Interaction Diagrams A First Look at Sequence Diagrams Objects Messages Control.
Designing with Interaction and Design Class Diagrams Chapters 15 & 16 Applying UML and Patterns Craig Larman With some ideas from students in George Blank’s.
1 Lab Beginning Analysis and Design 4 Completion of first version of use case diagram initiates the processes of analysis and design. 4 UML provides.
Unified Modeling Language
Chapter 7: The Object-Oriented Approach to Requirements
CS3773 Software Engineering
Interaction diagrams Sequence and collaboration diagrams.
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 25. Review Design Level Class Diagram Identifying classes/Operations/Attributes Associations – Simple associations.
System Sequence Diagrams. Recap When to create SSD? How to identify classes/instances? Use case descriptions UML notations for SSD.
1 On to Object Design Chapter 14 Applying UML and Patterns.
Other UML Diagramming Techniques CS 124. UML Diagramming Techniques Class Diagrams Use Case Diagrams Interaction Diagrams Sequence diagrams Collaboration.
Practical Object-Oriented Design with UML 2e Slide 1/1 ©The McGraw-Hill Companies, 2004 PRACTICAL OBJECT-ORIENTED DESIGN WITH UML 2e Chapter 9: Interaction.
Instructor: Tasneem Darwish1 University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Object Oriented.
Object-Oriented Design Notation CS 123/CS 231. References zMain Reference: UML Distilled, by Martin Fowler ÕChapters 3, 4, 6, and 8 zSupplementary References:
7 Systems Analysis and Design in a Changing World, Fifth Edition.
Sequence diagram in UML Martin Palkovik. Sequence diagram  It is a graphic representation of system operations based on chronology - a time sequence.
M Taimoor Khan Sequence Diagrams Illustrates how objects interacts with each other. Emphasizes time ordering of messages.
 C-style pointer-based arrays  Have great potential for errors and several shortcomings  C++ does not check whether subscripts fall outside the range.
Interaction Diagrams Interaction Diagrams allow the designer to show how groups of objects collaborate in some behavior. –Interaction Diagrams will show.
Sequence Diagrams Sequence; Interaction Diagrams Behavioral Diagrams
Interaction Diagram Notation
Object-Oriented Analysis and Design 1 Mira Balaban & Arnon Sturm Object-Oriented Analysis and Design Session 3a: Behavioral Modeling - Interactions.
Object Oriented Analysis and Design Sequence Diagrams.
Appendix D UML at a Glance Summary prepared by Kirk Scott 1.
System Sequence Diagram Chandan Rupakheti & Steve Chenoweth Week 5-3a.
CS212: Object Oriented Analysis and Design Lecture 34: UML Activity and Collaboration diagram.
Systems Analysis and Design in a Changing World, Fourth Edition
OOP Review CS 124.
Chapter 3: Introducing the UML
Interaction Diagrams CS 124. Object collaboration A use case carried out involves objects and interaction or collaboration between these objects Method.
Class Diagrams Software Design and Development. Classes in a Class Diagram zClass name onlyExample zWith DetailsExample Class Name attributes methods.
 The Sequence Diagram models the collaboration of objects based on a time sequence.  It shows how the objects interact with others in a particular scenario.
1 Kyung Hee University Interaction Diagrams Spring 2001.
UML Modeling Sequence diagram
Sequence Diagrams Mimi Opkins CECS 493 Fall2016
Chapter 11: Collaboration Diagram - PART1
COMP 2710 Software Construction Sequence Diagrams (cont.)
Sequence Diagram.
Prepared By Sidra Noureen
Software Design AITI GP John Paul Vergara.
SNSCT_CSE_PROGRAMMING PARADIGM_CS206
Sequence Diagrams.
Requirements To Design In This Iteration
Sequence Diagrams Lecture 6.
Sequence Diagrams.
Interaction diagrams.
UML Diagrams: Sequence Diagrams Dynamic Analysis Model
Unified Modelling Language
Chapter 9: Sequence Diagrams Chapter 5 in Software Engineering Book
Interaction diagrams Interaction diagrams are models that describe how groups of objects collaborate in some behavior. Typically, an interaction diagram.
Other UML Diagramming Techniques
Sequence Diagrams.
Chapter 9: Sequence Diagrams Chapter 5 in Software Engineering Book
Presentation transcript:

Interaction Diagrams CS 124

Object collaboration A use case carried out involves objects and interaction or collaboration between these objects Method calls between objects This collaboration is depicted in the UML through an Interaction Diagram Two types: Collaboration diagram Sequence diagram

Example: Collaboration Diagram Checkout Screen :Borrower :Book 1: checkIfDelinquent() 3: borrowBook() 2: checkIfAvailable() 4: setBorrower()

Interaction (Collaboration) Diagram Notation Rectangles: Classes/Objects Arrows: Messages/Method Calls Labels on Arrows sequence number (whole numbers or X.X.X notation) method name (the message passed) more details, if helpful and necessary (iterators, conditions, parameters, types, return types)

Methods Interaction Diagrams suggest/imply methods for classes Has consequences on detailed class diagram The label(s) of an arrow should be a method of the class the arrow points to Library System Borrower class should have at least two methods (checkIfDelinquent and borrowBook)

Including Conditions and Types Checkout Screen r:Borrower b:Book 1: delinq = checkIfDelinquent():boolean 3:[!delinq & avail] borrowBook(Book b) 2: avail = checkIfAvailable():boolean

Creating an Object new means a constructor is being called Implies object creation :Customer :CustomerList 1: addCustomer(custdetails) :Encoder 2: new Note: this means the addCustomer method will contain code that creates a Customer object

Iteration * is an iterator means the method is called repeatedly :Branch :Store 1: printSalesSummary() :Manager 2: * getTotalSales() Note: Store needs data from all branches to produce a summary

Sequence Diagram Variant of an interaction diagram that emphasizes sequence Objects shown as boxes on top of the diagram Dashed vertical line below the box: object’s lifeline Activation bar to indicate the object’s activation Sequence number unnecessary because top to bottom calling sequence is assumed Message notation the same as for collaboration diagrams

Collaboration versus Sequence Diagrams Use collaboration diagrams when you want to make use of a two-dimensional layout of interacting objects Ok when there aren’t that many objects Use sequence diagrams when layout doesn’t help in presentation and when you want to clarify calling sequence