Presentation is loading. Please wait.

Presentation is loading. Please wait.

Use Case Maps (UCMs) and UML Use Case Diagrams SEG3201 Fall 2006.

Similar presentations


Presentation on theme: "Use Case Maps (UCMs) and UML Use Case Diagrams SEG3201 Fall 2006."— Presentation transcript:

1 Use Case Maps (UCMs) and UML Use Case Diagrams SEG3201 Fall 2006

2 © 2006 Page 2 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) Include Relationship u Helps to clarify a use case by isolating and encapsulating complex details and by improving consistency. u Base use case requires included use case for completion u Solution: Use static stubs on the path representing a base use case. – Stubs hide the details contained in their plug-ins (the included use case) – The plug-in can be reused in multiple stubs, hence improving consistency among the UCMs.

3 © 2006 Page 3 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) req msg ring Basic Call Include Relationship: Example Basic Call Originating « include » OCS Call « include » Terminating « include » TerminatingOriginating req msg ring OCS OCS Call Terminating

4 © 2006 Page 4 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) Extend Relationship u Shows that part of a use case is: – (potentially) optional; – executed only under certain conditions; – inserted at an extension point in a base use case; – not required for the completion of base use case. u Solution: Use (guarded) OR-forks or dynamic stubs on a base use case. – Extension points are visual. – For dynamic stubs, there is a default plug-in that represents the original base case.

5 © 2006 Page 5 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) Extend Relationship: Example Basic Call Busy Treatment « extend » OCS Feature « extend » OCS plug-in in1 out2 out1 chk [allowed] [denied] md OCSlist in1 out1 Default plug-in req ring Basic Call Originating upd msg [idle] [busy] mb Selection Strategy

6 © 2006 Page 6 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) Generalization Relationship u Used when two or more use cases have commonalties in behavior, structure, and purpose. The shared part can then be described in a new parent use case specialized by child use cases. u Solution: Use OR-joins and OR-forks, or multiple dynamic stubs. – Parent use case contains dynamic stubs for diverging behavior. – Child use case is parent + plug-ins.

7 © 2006 Page 7 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) Generalization Relation:Example Phone Session req msg ring Phone Session Originating UserOAgentOUserTAgentT Basic Call =Phone Session + Originating plug-in OCS Call =Phone Session + OCS plug-in Basic Call OCS Call

8 © 2006 Page 8 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) User Elevator Control System in elevator at requested floor Arrival Sensor approaching floor add to list [else] no requests [stationary] [moving] [not requested] door close motor up motor down moving decide on direction Select Destination motor stop [requested] door open remove from list [more requests] The elevator control system is adapted from Hassan Gomaa (2001) Designing Concurrent, Distributed, And Real-Time Applications with UML. Addison Wesley p459-462. press number

9 © 2006 Page 9 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) Elevator Control System [stationary] add to list User at floor select elevator Request Elevator press up/down

10 © 2006 Page 10 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) User Arrival Sensor Elevator Control System decide on direction door close motor up motor down select elevator approaching floor [not requested] at requested floor [stationary] [more requests] [else] no requests [moving] Both Use Cases motor stop door open add to list moving [requested] remove from list in elevator press number at floor press up/down

11 © 2006 Page 11 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) User in elevator press number at floor press up/down [stationary] [more requests] [else] no requests [moving] Arrival Sensor Elevator Control System decide on direction door close motor up motor down select elevator approaching floor [not requested] at requested floor motor stop add to list moving stationary [requested] door open Service Personnel switch on remove from list Both Use Cases + Switch On [stat.]

12 © 2006 Page 12 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) remove from list User in elevator press number at floor press up/down decide on direction door close motor up motor down [not requested] moving [requested] motor stop door open Arrival Sensor Elevator Control System select elevator approaching floor at requested floor add to list stationary Service Personnel switch on IN1 OUT1 Dispatch Elevator IN1 OUT1 IN2 Stop Elevator at Floor Included Use Cases [moving] [stat.]

13 © 2006 Page 13 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) High Level UCM User start walk_IN OUT1 IN1 Request Elevator Request Elevator bindings: IN1 … at floor OUT1 … at requested floor Select Destination bindings: IN1 … in elevator OUT1 … at requested floor OUT1 IN1 Select Destination end walk_OUT

14 © 2006 Page 14 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) User Arrival Sensor Service Personnel Scheduler Elevator decide on direction [stat.] door close motor up motor down moving select elevator approaching floor [not requested] motor stop [requested] door open at requested floor stationary switch on add to list [moving] remove from list Arch. Alternative (I) in elevator press number at floor press up/down

15 © 2006 Page 15 SEG3201 / Fall 2006 UCM and Use Cases (Elevator Control System) UCM and Use Cases (Elevator Control System) in elevator press number at floor press up/down User Service Personnel Elevator Scheduler Status&Plan Elev. Control Elev. Mgr decide on direction [stat.] door close motor up motor down moving select elevator Arrival Sensor approaching floor [not requested] motor stop door open stationary switch on add to list [moving] [requested] remove from list at requested floor Arch. Alternative (II)


Download ppt "Use Case Maps (UCMs) and UML Use Case Diagrams SEG3201 Fall 2006."

Similar presentations


Ads by Google