NCKU EE RTES LAB.1 Unified Modeling Language - Events and State Machines.

Slides:



Advertisements
Similar presentations
Methoden …\uml.ppt Folie:1 Rainer Kröning Unified Modeling Language.
Advertisements

State Diagram 1. State diagram: Shows the behavior of one object. They describe all of the possible states that a particular object can get into and how.
Concepts & Notations. Acknowledgements  The material in this tutorial is based in part on: Concurrency: State Models & Java Programming, by Jeff Magee.
Karolina Muszyńska Based on: S. Wrycza, B. Marcinkowski, K. Wyrzykowski „Język UML 2.0 w modelowaniu SI”
ESE Einführung in Software Engineering 7. Modeling Behaviour Prof. O. Nierstrasz.
1 Chapter 4 Dynamic Modeling and Analysis (Part I) Object-Oriented Technology From Diagram to Code with Visual Paradigm for UML Curtis H.K. Tsang, Clarence.
1 Chapter 4 Dynamic Modeling and Analysis (Part I) Object-Oriented Technology From Diagram to Code with Visual Paradigm for UML Curtis H.K. Tsang, Clarence.
Unified Modeling Language Unit 4. Dynamic Modeling.
March R. McFadyen1 Statechart Diagram A Statechart Diagram describes states for an object how/why an objects’ state changes A Statechart Diagram.
Slide 1 Systems Analysis & Design CS183 Spring Semester Dr. Jonathan Y. Clark Course Website:
1 © Wolfgang Pelz UML2 UML Part 3. 2 © Wolfgang Pelz UML2 Chapter Ten State Machine Diagrams.
THE OBJECT-ORIENTED DESIGN WORKFLOW Statechart Diagrams.
State Change Modelling. Aim: To introduce the concept and techniques for describing the changes in state that may occur to an object in its lifetime.
Advanced Behavioral Modeling
Practical Object-Oriented Design with UML 2e Slide 1/1 ©The McGraw-Hill Companies, 2004 PRACTICAL OBJECT-ORIENTED DESIGN WITH UML 2e Chapter 10: Statecharts.
SE-565 Software System Requirements More UML Diagrams.
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.
Karolina Muszyńska Based on: S. Wrycza, B. Marcinkowski, K. Wyrzykowski „Język UML 2.0 w modelowaniu SI”
State and Sequence Diagrams Modelling dynamic information So far we have seen: Use Case Diagrams – requirements capture, interface.
CS451 Introduction to Software Engineering Behavioral Modeling.
Lecture 4 Finite State Machine CS6133 Software Specification and Verification.
Timed UML State Machines Ognyana Hristova Tutor: Priv.-Doz. Dr. Thomas Noll June, 2007.
Chapter 10 State Machine Diagrams
(C) 2009 J. M. Garrido1 Object Oriented Simulation with Java.
מידול התנהגותי 1. Today’s Session Sequence Diagrams State Machines 2.
Interaction diagrams Sequence and collaboration diagrams.
1 Object-Oriented Modeling Using UML (2) CS 3331 Fall 2009.
State diagrams Interaction diagrams –Sequence diagrams –Collaboration diagrams Object orientation Part 4: Dynamic Modeling.
1 Software Engineering Dr. K. T. Tsang Lecture 8 State modeling
Behavioral diagrams Lecture p4 T120B pavasario sem.
Object-Oriented Modeling Using UML CS 3331 Section 2.3 of Jia 2003.
Sequence & Statechart Diagrams Month Day, Year. Agenda Training Plan Overview Actors and Use Case Diagrams Sequence Diagrams Diagram Elements Evolution.
UML -Part 3. Dynamic Diagram Types Interaction Diagrams - Set of objects or roles and the messages that can be passed among them. – Sequence Diagrams.
1 A Student Guide to Object- Oriented Development Chapter 7 State Diagrams.
Smith’s Aerospace © P. Bailey & K. Vander Linden, 2005 Interaction and Communication Diagrams Patrick Bailey Keith Vander Linden Calvin College.
The Unified Modeling Language Part II Omar Meqdadi SE 2730 Lecture 9 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
Software Engineering Design & Modeling Statechart Diagram.
1 Kyung Hee University Statecharts Spring Kyung Hee University Specifying Objects’ Behaviour  Interaction diagrams show message-passing behaviour.
UML Discussion on State Machines Perfectly static system is intensely uninteresting Because nothing ever happens.
State Modeling. Introduction A state model describes the sequences of operations that occur in response to external stimuli. As opposed to what the operations.
Karolina Muszyńska Based on: S. Wrycza, B. Marcinkowski, K. Wyrzykowski „Język UML 2.0 w modelowaniu SI”
Object Oriented Analysis & Design & UML (Unified Modeling Language)1 Part VI: Design Continuous Activity Diagams State Diagrams.
States.
CS3773 Software Engineering Lecture 06 UML State Machines.
Practical Object-Oriented Design with UML 2e Slide 1/1 ©The McGraw-Hill Companies, 2004 PRACTICAL OBJECT-ORIENTED DESIGN WITH UML 2e Chapter 10: Statecharts.
Modeling Object Lifecycles and State-Dependent Behavior ©SoftMoore ConsultingSlide 1.
 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.
Chapter 7 Behavioral Modeling Brandon A. Jones Stand and Deliver ITEC March 6, 2011.
Test Generation from UML Specifications Michael A. Gray American University Washington, DC.
ITEC1301 Object-Oriented Systems Construction Lecture Notes #4 1.
State Modeling. Introduction A state model describes the sequences of operations that occur in response to external stimuli. As opposed to what the operations.
UML Review: State Machines. Sept. 17, 2003Lecture 5: CS660 Fall Overview States Transitions Activities Modeling object lifeline Creating well-structured.
State transition modeling
State Machine Model.
State Diagram – Advanced Concepts
Marlon Dumas Institute of Computer Science
State Machine Diagrams
UML State Diagrams.
Dynamic Modeling: Defining Classes
CSC 422 Kutztown University Dr. Spiegel
UML Activity Diagrams & State Charts
States.
Object Oriented System Design
Chapter 5 state Modeling
Marlon Dumas Institute of Computer Science
States.
DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING
UML State Diagrams.
Behavioral Diagrams P. P. Mahale
UML State Diagrams (Ch. 29)
Presentation transcript:

NCKU EE RTES LAB.1 Unified Modeling Language - Events and State Machines

NCKU EE RTES LAB. 2 Events An events is the specification of a significant occurrence that has a location in time and space. In the UML, there are four kinds of events: signals calls the passing of time a change in state

NCKU EE RTES LAB. 3 A signal represents a named object that is dispatched asynchronously by one object and then received by another. Signals have a lot in common with plain classes. A call event represents the dispatch of an operation. A call event is synchronous. Signals an Call Events

NCKU EE RTES LAB. 4 Signals and Call Events A signals may be sent as the action of a state transition in a state machine or the sending of a message in an interaction. When an object invokes an operation on another object, control passes from the sender to the receiver, the operation is completed, control returns to the sender. MovementAgent position velocity moveTo() > Collision force:Float > Manual Automatic startAuotopilot(normal)

NCKU EE RTES LAB. 5 Signals and Call Events Any instance of any class can send a signal to or invoke an operation of a receiving object. When an object sends a signal, the sender dispatches the signal and then continues along its flow of control, not waiting for any return from the receiver. When an object calls an operation, the sender dispatches the operation and then waits for the receiver.

NCKU EE RTES LAB. 6 Time and Change Events after - A time event is an event that represents the passage of time. when - A change event is an event that represents a change in state or the satisfaction of some condition. Idle Active after (2 seconds) / dropConnection() when (11:49PM) / selfTest()

NCKU EE RTES LAB. 7 State Machine Interaction can model the behavior of a society of objects that work together. State machine can model the behavior of an individual object. A state machine is a behavior that specifies the sequences of states an object goes through during its lifetime in response to events.

NCKU EE RTES LAB. 8 Terms A state is a condition or situation during the life of an object during which it satisfies some condition, performs some activity, or waits for some event. In the context of state machines, an event is an occurrence of a stimulus that can trigger a state transition. A transition is a relationship between two states indicating that an object in the first state will enter the second state.

NCKU EE RTES LAB. 9 States Name – a textual string Entry/exit actions – actions executed on entering and exiting the state Internal transitions – transitions that are handled without causing a change in state Substates – the nested structure of a state Defferred events – a list of events that are not handled in that state but, are postponed and queued for handling by the object in another state Initial and final states

NCKU EE RTES LAB. 10 Transitions Source state – the state affected by the transition Event trigger – the event whose reception by the object in the source state makes the transition eligible to fire Guard condition – a boolean expression that is evaluated when the transition is triggered by the reception of the event trigger Action – an executable atomic computation Target state – the state that is after the completion of the transition Note: A change of state is said to fire.

NCKU EE RTES LAB. 11 IdleSearchingEngaging Tracking Engaging After (2 seconds) / send c.isAlive noise contact targetAt(p) [isThreat] / t.addTarget(p) time event send signal self-transition event trigger triggeriess transition event trigger with parameters guard condition action

NCKU EE RTES LAB. 12 Cooling Idle Activating Active tooCold(desiredTemp) shutDown tooHot(desiredTemp) atTemp tooHot(desiredTemp) tooCold(desiredTemp) atTemp Heating ready/turnOn() event initial state state final state event parameter event state transition nested state