Eshcar Hillel Unified Modeling Language - UML A specification language for object modeling Industry-standard Simplifies the complex process of design Create a "blueprint" for construction Visualize the system model with a standardized graphical notation Document the artifacts of software systems UML tools Many products to chose from on the market today Rational (IBM ), Rhapsody (I-Logix) 2 1
Previously on The Lecture Use case describes what the system, as a black box, does from an actor s perspective A use case is a sequence of transactions in a system whose task is to yield a measurable value to an actor System [Ivar Jacobson 95] 3 Tutorial Outline Use case diagram System boundaries Actors and their relationships Use cases and their relationships Use case specification Described textually Traceability Cross-reference between operational requirements and the use cases that cover them 4 2
Use Case Diagram System boundary More than it captures what the system includes it captures what it is not Actor represents a role Person Hardware Software Use case represents a behavior System 5 Actors Relationships An actor may generalize another actor The specialized actor inherits the behavior of the general actor and extend it in some way employee Marketing manager 6 3
Use Cases Relationships Generalization X Factors common constraints and assumptions Either X or Y is executed Inclusion X Y Captures a truly common behavior for multiple use cases X always involves doing Y Extension << include >> << extend >> X Serves as extension point to another Use Case Y involves doing X under some conditions Y Y 7 Use Case Diagram: BrighTask Example Create Version BrighTask <<include>> <<include>> Checkout Check-in <<include>> Finish Branch <<extend>> <<extend>> Merge File Create Branch Override File Merge No Conflicts Merge Resolve Conflicts 8 4
RAMSEY user RAMSEY Course Schedule event secretary Conference Initialization administrator coordinator 9 mail application RAMSEY - Variation I user RAMSEY Schedule event secretary Room Initialization administrator coordinator 10 mail application 5
RAMSEY - Variation II user Course RAMSEY Schedule event secretary coordinator Conference Room Initialization administrator 11 mail application Use Case Specification Use case name and goal Actors list Reference to requirements Pre-conditions Post-conditions Trigger event Main Success Scenario Alternatives Exceptions Pre-conditions Post-conditions 12 6
Schedule Event Example (I) Name Schedule event Goal Schedule a room for an event in a specific time frame Actors user, mail applications Requirements ref. 30, 31, 33, 34, 35, 36, 37, 38 Don t forget me!! 13 Schedule Event Example (II) Pre-conditions None Post-conditions The event is registered in the system; the room is reserved for the event in the designated time; What about: the system is initialized? and all persons in the distribution list received a notification regarding the event 14 7
15 Schedule Event Example (III) Trigger Event The user requests to schedule an event Main Success Scenario 1. The system displays an event form 2. The user enters the event information in the form 3. The system presents a list of all available rooms, which meet all the requirements 4. The user selects a room from the list 5. The system presents the final details of the request 6. The user approves the event A non-internal use case is always initiated by an actor!! This is a potential pre-condition Note the ping-pong between the user and the system Schedule Event Example (IV) Main Success Scenario (cont.) 7. The system offers to send a notification message 8. The user selects a distribution list and composes the body of the message 9. The system forwards the message including the event information to the mail application 10. The mail application confirms sending the message 11. The system confirms the end of the scheduling process 16 8
Matches the use case indices Schedule Event Example (V) Alternatives Maybe should consider this as an extending use case 3. a. [All matching rooms are unavailable] b. The system suggests alternative rooms c. The user selects an alternative room d. proceed with step #6 8. a. The user chooses not to send notification b. The system confirms the end of the scheduling process 17 Schedule Event Example (VI) Exceptions 6. a. The user aborts Instead of approving b. The system exit the process without registering the event 18 9
Traceability ID Description Type Comments Use Case 014 Prior to the beginning of Operational Course 015 The authorized secretary Operational Course 016 The information regarding Data 017 The system presents Operational Course 19 10