CS48711-1/31 Illinois Institute of Technology CS487 Software Engineering OOA with UML David Lash.

Slides:



Advertisements
Similar presentations
A Brief Introduction. Acknowledgements  The material in this tutorial is based in part on: Concurrency: State Models & Java Programming, by Jeff Magee.
Advertisements

Chapter 22 Object-Oriented Systems Analysis and Design and UML Systems Analysis and Design Kendall and Kendall Fifth Edition.
Unified Modeling Language
Object-Oriented Analysis and Design
2-1 © Prentice Hall, 2007 Chapter 2: Introduction to Object Orientation Object-Oriented Systems Analysis and Design Joey F. George, Dinesh Batra, Joseph.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 8 Slide 1 System models.
L4-1-S1 UML Overview © M.E. Fayad SJSU -- CmpE Software Architectures Dr. M.E. Fayad, Professor Computer Engineering Department, Room #283I.
CS 425/625 Software Engineering System Models
Modified from Sommerville’s originalsSoftware Engineering, 7th edition. Chapter 8 Slide 1 System models.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 8 Slide 1 System models September 29, 2008.
Modified from Sommerville’s originalsSoftware Engineering, 7th edition. Chapter 8 Slide 1 System models.
© Copyright Eliyahu Brutman Programming Techniques Course.
UML Sequence Diagrams Eileen Kraemer CSE 335 Michigan State University.
Sharif University of Technology1 Design and Use-case Realization Software Engineering Laboratory Fall 2006.
1 CS 426 Senior Projects Chapter 1: What is UML? Chapter 2: What is UP? [Arlow and Neustadt, 2002] January 26, 2006.
Unified Modeling Language
1 Introduction to UML DIAGRAMS & CLASS DIAGRAM Chapter 7,8 主講人 : 許勝杰
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 7 Slide 1 System models l Abstract descriptions of systems whose requirements are being.
What is UML? What is UP? [Arlow and Neustadt, 2005] January 23, 2014
SOFTWARE ENGINEERING BIT-8 APRIL, 16,2008 Introduction to UML.
©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.
CIT UPES | Sept 2013 | Unified Modeling Language - UML.
System models Abstract descriptions of systems whose requirements are being analysed Abstract descriptions of systems whose requirements are being analysed.
©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: 
1 UML Basic Training. UML Basic training2 Agenda  Definitions: requirements, design  Basics of Unified Modeling Language 1.4  SysML.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 8 Slide 1 Object-oriented and Structured System Models.
Chapter 7 System models.
Slide 1 System models. Slide 2 Objectives l To explain why the context of a system should be modelled as part of the RE process l To describe behavioural.
System models l Abstract descriptions of systems whose requirements are being analysed.
Pertemuan 19 PEMODELAN SISTEM Matakuliah: D0174/ Pemodelan Sistem dan Simulasi Tahun: Tahun 2009.
Modified by Juan M. Gomez Software Engineering, 6th edition. Chapter 7 Slide 1 Chapter 7 System Models.
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.
1 Software Engineering: A Practitioner’s Approach, 6/e Chapter 8: Analysis Modeling Software Engineering: A Practitioner’s Approach, 6/e Chapter.
UML diagrams What is UML UML diagrams –Static modeoing –Dynamic modeling 1.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 7 Slide 1 Chapter 7 System Models.
TAL7011 – Lecture 4 UML for Architecture Modeling.
1 The Unified Modeling Language. 2 The Unified Modeling Language (UML) is a standard language for writing software blueprints. The UML may be used to.
UML as a Specification Language for Embedded Systems. By, Mir Ahmed Ali, Asst. Professor, ECM department, SNIST. By, Prof. Narsiah sir, Director of School.
Logical view –show classes and objects Process view –models the executables Implementation view –Files, configuration and versions Deployment view –Physical.
Unified Modeling Language User Guide Section 4 - Basic Behavioral Modeling Chapter 16 - Use Cases Chapter 17 - Use Case Diagrams.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 8 Slide 1 System models.
Lecture 9-1 : Intro. to UML (Unified Modeling Language)
1 Technical & Business Writing (ENG-715) Muhammad Bilal Bashir UIIT, Rawalpindi.
Week 04 Object Oriented Analysis and Designing. What is a model? A model is quicker and easier to build A model can be used in simulations, to learn more.
Lecture 14 22/10/15. The Object-Oriented Analysis and Design  Process of progressively developing representation of a system component (or object) through.
21/1/ Analysis - Model of real-world situation - What ? System Design - Overall architecture (sub-systems) Object Design - Refinement of Design.
 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.
CSCI 383 Object-Oriented Programming & Design Lecture 7 Martin van Bommel.
Unified Modeling Language. What is UML? Standard language for specifying, visualizing, constructing, and documenting the artifacts of software systems,
1 IS 0020 Program Design and Software Tools Unified Modeling Language Lecture 13 April 13, 2005.
1 IS 0020 Program Design and Software Tools Unified Modeling Language Lecture 13 November 30, 2004.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 8 Slide 1 System models.
Slide 1 Unified Modeling Language, Version 2.0 Object-Oriented SAD.
Engineering, 7th edition. Chapter 8 Slide 1 System models.
Object-oriented and Structured System Models
UML Diagrams By Daniel Damaris Novarianto S..
Course Outcomes of Object Oriented Modeling Design (17630,C604)
Object-Oriented Analysis and Design
Unified Modeling Language
Introduction to Unified Modeling Language (UML)
UML Diagrams Jung Woo.
Abstract descriptions of systems whose requirements are being analysed
Object-Oriented Analysis
The Unified Modeling Language
Unified Modeling Language
Software Design Lecture : 15.
Chapter 22 Object-Oriented Systems Analysis and Design and UML
Presentation transcript:

CS /31 Illinois Institute of Technology CS487 Software Engineering OOA with UML David Lash

CS /31 UML: An Overview u Unified Modeling Language – An out growth of OMT - Object Modeling Technique – OO Software Engineering u UML is a modeling language for – specifying - can be used to communicate "what" is required of a system, and "how" a system may be realized. – visualizing - it can be used to visually depict a system before it is realized. – constructing, - can be used to guide the realization of a system similar to a "blueprint". – documenting - can be used for capturing knowledge about a system throughout its life-cycle u the artifacts of a system to derive or evolve a system.

CS /31 UML: An Overview u The UML is not:  A visual programming language, but a visual modeling language.  A tool or repository specification, but a modeling language specification.  A process, but enables processes. u Fundamentally, the UML is concerned with capturing, communicating, and levering knowledge

CS /31 UML: An Overview u UML applies to a multitude of different types of systems, domains, and methods or processes. It is – A general-purpose modeling language - focuses on acquiring, sharing, and utilizing knowledge coupled with extensibility mechanisms.  Broadly applicable modeling language - applicable to different types of systems, domains, and methods or processes.  Tool-supported modeling language - tools are available to support the application of the language to specify, visualize, construct, and document systems.  Industry-standardized modeling language, - not a proprietary and closed language but an open and fully extensible industry-recognized language.

CS /31 UML: Views u Unified Modeling Language supports 5 views to use diagrams to describe the system from different perspectives – User Model View - Use-case modeling approach to representation of the end-user’s perspective. – Structured Model View - Data and functionality viewed from inside the system (classes, objects & relationships) – Behavior View - models the behaviours and interactions of various structures – Implementation model view - the structural and behavior aspects of the system – Environment Model View - structural and behaviour aspects of the environment

CS /31 UML: Views u Unified Modeling Language supports 5 views to use diagrams to describe the system from different perspectives – User Model View - Use-case modeling approach to representation of the end-user’s perspective. – Structured Model View - Data and functionality viewed from inside the system (classes, objects & relationships) – Behavior View - models the behaviours and interactions of various structures – Implementation model view - the structural and behavior aspects of the system – Environment Model View - structural and behaviour aspects of the environment

CS /31 UML: Uses a variety of Diagrams u Use Case – Show a set of use cases and actors and their relationships u Actors: entities that interact with the system u Class – Show a set of classes, interfaces and collaborations and their relationships

CS /31 UML: Diagrams u Interaction – Sequence and collaboration – Show an interaction, consisting of a set of objects and their relationships u Dependency – A relationship between two elements in which a change to one element may affect or supply information needed by the other element.

CS /31 UML: Diagrams u State – Shows behavior a class or use case. – Different notation u Activity – Show the flow from activity to activity within a system

CS /31 UML: Diagrams u Component – Show the organizations and dependencies among a set of components (subsystem) u Deployment – Show the configuration of run-time processing nodes and components that live on them

CS /31 The OOA process u Use-cases u CRC modeling (Class-Responsibility- Collaborator modeling) - class definition & definiing hierarchies u Object-relationship modeling - ERD like u Object Behaviour modeling – state representations, event flow – event trace

CS /31 UML: Diagrams - Use Case u Description – A diagram that shows a set of use cases and actors and their relationships u Use Case - purpose – Defines functional & operational requirements of the system – Clear & unambiguous description of how the end-user & system interact (system’s context) – provide basis for validation testing u Introduced by Ivar Jacobson - Replace Data Flow Diagram used in OMT

CS /31 Use Case: Terms u Terms – Actor u An abstraction for entities outside a system, subsystem, or class that interact directly with the system. – Classifier u A model element that describes behavioral and structural features – Use Case u The specification of sequences of actions, including variant sequences and error sequences, that a system, subsystem, or class can perform by interacting with outside actors.

CS /31 UML: Diagrams u Use Case – Show a set of use cases and actors and their relationships u Actors: entities that interact with the system u Example: Consider homesafe with actors: – homeowner, sensors, & monitoring & response subsystem – Look only at homeowner for now

CS /31 Use Case: Actor Relationships

CS /31 Use Case HL Diagram - I Configures Interacts

CS /31 Use Case HL Diagram - II The Interacts Function Inputs Passwords Inquire zone status Press Panic Button Activates/ deactivates system Validates Password Uses Query Sensor Uses

CS /31 Use Case: Symbols

CS /31 Use Case: Relationship

CS /31 Use Case Example

CS /31 Hints and Tips u A well-structured Use Case diagram: – Focus on communicating one aspect of a system’s static Use Case view – Contain only those use cases and actors that are essential to understanding that aspect – Provide detail consistent with its level of abstraction; you expose only those adornments that are essential to understanding – Is not so minimalist as to misinform the reader about the semantics that are important

CS /31 Hints and Tips u When you draw a Use Case diagram – Give it a name that communicates its purpose – Lay out its elements to minimize lines that cross – Organize its elements spatially so that behaviors and roles that are semantically close are laid out physically close – Use notes and color as visual cues to draw attention to important features of your diagram – Try not to show too many kinds of relationships

CS /31 The OOA process u Use-cases u CRC modeling (Class-Responsibility- Collaborator modeling) - class definition & definiing hierarchies – Object-relationship modeling - ERD like u Object Behavior modeling – state representations, event flow – event trace

CS /31 CRC modeling (Class- Responsibility-Collaborator modeling) - class definition & defining hierarchies u A simple means for identifying and organizing classes

CS /31 Selecting Objects (review) u Already spoke about the Six characteristics that should be used on each potential object: – Retained Information - information about it must be remembered – Needed services - have a set of identifiable operations that can change attribute’s value – Multiple Attributes - Are the attributes “major” and useful? – Common Attributes - can define a set that apply to all occurrences of object – Essential requirements - External entity in problem and produces information essential to solution

CS /31 Collaborations- Defining relatips between Classes u A Class can : – use its operations to manipulate its own attributes or – collaborate with other classes if it cannot complete its responsibilities by itself u Review classes & determine relationship type: – is-part-of relationship - All classes part of an aggregate class. Player_body is part of player, player_arms is part of player. – has-knowledge-of relationship - when 1 class must acquire information from another. Control_panel object must determine if any sensors are open. determine_sensor_status relationship between them. Control_panel must work with sensor to get status. – depends-upon relationship - 2 classes have a dependency that is not 1 of the 2 above - Player_head must always be connected to player-body. (yet they can exist w/o knowledge of eachother).

CS /31 UML: Create Class Diagram u Use the Class diagram to – Show a set of classes, interfaces and collaborations and their relationships – Focuses on the the structure of the classes & hierarchies u Components – Name – Attributes – Operations – Responsibilities

CS /31 UML: Class Symbol

CS /31 UML: Class Diagram Chart Structure After ID classes & objects, => determine structure. - Objects might be generalization/specialization structure. - Sensor is the generalization of the specialized entry, smoke & motion sensors

CS /31 UML: Class Diagram - Showing Relationships - The object might be composed of a number of objects - The diamond implies an assembly relationship of the composite aggregate.

CS /31 UML: Class Diagram u Relationships – Dependency u A relationship that states that a change in specification of one thing may affect another thing that uses it, but not necessarily the reverse – Generalization (Inheritance) u A relationship between a general thing (parent, super-class) and a more specific kind of that thing

CS /31 UML: Class Diagram u Relationships – Association u A structural relationship that specifies that objects of one thing are connected to objects of another u Characteristics – Name – Role – Multiplicity – Aggregation u Components that comprise the owning object

CS /31 UML: Class Relationships

CS /31 UML: Class Association

CS /31 UML: Class Association

CS /31 UML: Class Association Indicates many

CS /31 UML: More On Cardinality

CS /31 UML: Class Aggregation Evaluate cardinality it can be: 0 to 1, 1 to 1, 0 to many, 1 to many.

CS /31 Identifying Classes Develop an automated student registration system. The students registration system identify the School (i.e. Arts & Sciences, Engineering, Fine Arts, etc.) in which the student is registered. It also shall Identify the current classes offered by each department and the instructor for each class.

CS /31 UML: Class Diagram Example

CS /31 The OOA process u Use-cases u CRC modeling (Class-Responsibility- Collaborator modeling) - class definition & definiing hierarchies – Object-relationship modeling - ERD like u Object Behavior modeling – state representations, event flow – event trace

CS /31 State Transitions u Within OO systems look at state that are: – state of each object as system performs its function – State of system as observable from the outside world (as system works) u Types – Active State transition diagram - u passive state => the current status of all attributes. E.g., video_game_player might have position, orientation u active state => the status of the object as it undergoes a transformation, moving, at rest, injured, being cured. u Action occurs concurrently with the state transition

CS /31 UML: Activity Diagram

CS /31 State Transitions u Within OO systems look at state that are: – state of each object as system performs its function – State of system as observable from the outside world (as system works) u Types – Event trace model - u how events cause transitions from object to object u key objects only – Event flow model

CS /31 UML: Interaction Diagram

CS /31 State Transitions u Within OO systems look at state that are: – state of each object as system performs its function – State of system as observable from the outside world (as system works) u Types – Event trace model (ETM) - u how events cause transitions from object to object u key objects only – Event flow model - u After ETM, collect events causing transitions between objects collated into inputs & outputs from object(s) u All events that flow into & out of object shown u Once done can do more detailed state diagram

CS /31 Partial Event Flow Diagram