SE311 · Annotated SlidesChapter 5.5 — Use-Case Model Exercise: the Movie Shop
Chapter 5.5 · Annotated slides

Use-Case Model Exercise: the Movie Shop

From the Movie Shop requirements to a use-case model: identifying actors and their functionality, grouping functionality into use cases, the initial and refined use-case diagrams, common errors, and the Reserve Movie use case.

Slide text Study notes Highlight: key words Tips, tricks & traps Seen again elsewhere How it can come up
Slide 1: EXERCISE: MOVIE SHOP USE-CASE MODEL
Exam weight Low

    • These reviews should be anonymous if the customer so wishes (i.e., customers can specify whether they want their name to be made known when other customers browse the reviews).
    • A sales clerk should be able to enter and update the following information about all customers (members or nonmembers): name, address, phone number, age, sex, and email address.
    • Members are assigned a membership number by the shop when they become members and a password, which allows them to change their personal information and to buy and rent digital movies via the Web.
    • The shop manager should be able to generate various reports on the sale and rental of movies.
    • A sales clerk should be able to sell and rent physical movies and process the return of rented physical movies.
    • When selling or renting physical movies, a sales clerk must be able to look up customer information and determine whether the customer is a member.
    • A sales clerk must be able to enter basic information about a movie (i.e., movie id, title, leading actor(s), director, producer, genre, synopsis, release year, running time, selling price, and rental price).
    Slide 2
    2
    Exam weight Low

      From the movie sales and rental shop requirements statement:

      identify all actors and their required functionality.

      a) b)

      group the functionality into use cases and show the uses cases and their related actors in a use-case context diagram.

      Slide 3
      3
      Exam weight Low

        EXERCISE: MOVIE SHOP USE-CASE MODEL ANALYSIS

        We first analyze the system's functional requirements and then present the use-case model. For the purposes of producing the use-case model, we are only interested in those functional requirements that provide something of value for some actor.

        • The system must be able to handle both physical and digital movies. functionality: None. This is an implementation requirement.
        • It must be able to record which movies are sold and rented and by whom. functionality: Someone: buy movie Someone: rent movie
        • For sold movies, the quantity sold should be recorded; for physical movie rental, which copy is rented and when it is due back should be recorded. functionality: Someone: enter movie quantity sold Someone: enter movie copy rented and due date
        4
        Exam weight High
        1. Identify actors (roles outside the system: Customer, Member, Clerk, Manager) and what each needs to do.
        🎯 How this can come up · 1 question
        MCQ

        In a use-case model, an actor is:

        EXERCISE: MOVIE SHOP USE-CASE MODEL ANALYSIS

        • The system should keep track of overdue rentals of physical movies and send email notices to customers who have movies overdue. functionality: Customer: receive overdue notice Note that how the notice is received (i.e., by email) is not important from a functionality perspective.
        • There will be a customer membership option for an annual fee, which will entitle a member to discounts (10%) on the sale and rental of movies. functionality: Someone: enter member information Member: get discount
        • Members should be able to make reservations for physical movie rentals either in person at the shop, by telephone or via the Web. functionality: Member: reserve movie Sales clerk: reserve movie Note that how the reservation is done is not important from a functionality perspective.
        5
        Exam weight Low

          EXERCISE: MOVIE SHOP USE-CASE MODEL ANALYSIS

          • A member can reserve at most five physical movies at any one time, but there is no limit on how many physical movies a member or nonmember can rent at any one time. functionality: No new functionality.
          • As an added feature, the shop would like to allow customers (either members or nonmembers) to input, via the Web, mini-reviews (up to 100 words) and a rating (from 1, lowest, to 10, highest) of movies they have purchased or rented. functionality: Customer: enter movie review
          • These reviews should be anonymous if the customer so wishes (i.e., customers can specify whether they want their name to be made known when other customers browse the reviews). functionality: Customer: browse movie reviews
          6
          Exam weight Low

            EXERCISE: MOVIE SHOP USE-CASE MODEL ANALYSIS

            • A sales clerk should be able to enter and update the following information about all customers (members or nonmembers): name, address, phone number, age, sex, and email address. functionality: Sales clerk: enter customer information Supersedes the requirement regarding someone entering member information. Sales clerk: update customer information
            • Members are assigned a membership number by the shop when they become members and a password, which allows them to change their personal information and to buy and rent digital movies via the Web. functionality: Member: update personal information Member: buy movie Member: rent movie Clarifies who can use buy and rent functionality.
            • The shop manager should be able to generate various reports on the sale and rental of movies. functionality: Manager: generate reports
            7
            Exam weight Low

              EXERCISE: MOVIE SHOP USE-CASE MODEL ANALYSIS

              • A sales clerk should be able to sell and rent physical movies and process the return of rented physical movies. functionality: Sales clerk: buy (sell) movie Sales clerk: rent movie Sales clerk: return rented movie Clarifies who can use buy and rent functionality.
              • When selling or renting physical movies, a sales clerk must be able to look up customer information and determine whether the customer is a member. functionality: Sales clerk: lookup customer information
              • A sales clerk must be able to enter basic information about a movie (i.e., movie id, title, leading actor(s), director, producer, genre, synopsis, release year, running time, selling price, and rental price). functionality: Sales clerk: enter movie information While there may be other functionality that the system should support, here we will only deal with the functionality identified in the requirements statement in constructing the use-case model.
              8
              Exam weight Low

                EXERCISE: MOVIE SHOP USE-CASE MODEL ANALYSIS

                Actors

                A customer is someone who uses the system to enter

                Customer

                and browse reviews and who receives overdue notices from the system.

                A member is someone who has paid a membership fee

                Member

                to the shop. In addition to what a customer can do, a member can also use the system to buy or rent movies, to reserve movies and to access and change their personal information.

                Sales clerk A sales clerk is a shop employee who uses the system to

                sell and rent movies, to reserve movies, to process the return of rented movies and to enter and update movie and customer/member information.

                Manager

                A manager is a shop employee. In addition to what a sales clerk can do, a manager can also generate various reports on sales and rentals of movies.

                9
                Exam weight Low

                  EXERCISE: MOVIE SHOP USE-CASE MODEL FUNCTIONALITY ANALYSIS AND GROUPING

                  Member or Sales clerk Someone: enter movie quantity sold

                  Sales clerk

                  Someone: enter movie copy rented and due date Customer: receive overdue notice Member: get discount Member: reserve movie Sales clerk: reserve movie Customer: enter movie review Customer: browse movie reviews Sales clerk: enter customer information Sales clerk: update customer information Member: update personal

                  Should customer

                  information Member: buy movie

                  be an actor for

                  Member: rent movie

                  buy/rent movie?

                  Manager: generate reports Sales clerk: buy (sell) movie

                  No! Why?

                  Sales clerk: rent movie

                  Customers do not interact

                  Sales clerk: return rented movie

                  directly with the system to

                  Sales clerk: lookup customer information

                  buy/rent a movie.

                  Sales clerk: enter movie information

                  10
                  Exam weight Low
                  1. Group related functionality into use cases (one user goal each), not one use case per button.

                  EXERCISE: MOVIE SHOP USE-CASE MODEL FUNCTIONALITY ANALYSIS AND GROUPING

                  Member: buy movie Member: enter movie quantity sold Member: get discount

                  Buy Movie

                  Sales clerk: buy (sell) movie Sales clerk: lookup customer information Sales clerk: enter movie quantity sold Member: rent movie Member: get discount Sales clerk: rent movie Sales clerk: lookup customer information

                  Rent Movie

                  Sales clerk: enter movie copy rented and due date Sales clerk: return rented movie Customer: receive overdue notice

                  11
                  Exam weight Low
                    Slide 12: EXERCISE: MOVIE SHOP USE-CASE MODEL FUNCTIONALITY ANALYSIS AND GROUPING
                    Exam weight Low
                      Slide 13: EXERCISE: MOVIE SHOP INITIAL USE-CASE DIAGRAM
                      Exam weight Low
                      1. Initial diagram: actors linked to the use cases they start.
                      Slide 14: EXERCISE: MOVIE SHOP REFINED USE-CASE DIAGRAM
                      Exam weight Low
                      1. Refined diagram: generalize actors (Member is a Customer), factor shared steps with <<include>>, optional ones with <<extend>>.

                      EXERCISE: MOVIE SHOP USE-CASE MODEL COMMON ERRORS

                      System/devices/communication methods are not actors.

                      ⚫

                      (e.g., web, phone, etc. represent how something is done) ☞

                      Do not represent input/output devices as actors!

                      ⚫

                      The client organization is not an actor.

                      (e.g., Movie Shop) Too large or obscure use cases.

                      ⚫

                      (e.g., Shop For Movie, Provide Service To Customer) Too small use cases.

                      ⚫

                      ☞

                      Do not represent each operation/function as a use case!

                      ⚫

                      Give meaningful names to the use-cases.

                      (e.g., names too vague or too long)

                      15
                      Exam weight High
                      1. Common errors: use cases that are steps rather than goals, the system shown as an actor, functional decomposition, missing actors.
                      🎯 How this can come up · 1 question
                      MCQ

                      Which is a use-case modelling error?

                      EXERCISE: MOVIE SHOP USE-CASE MODEL COMMON ERRORS

                      Do not represent nonfunctional requirements.

                      ⚫

                      (e.g., 10% discount) Login is not a functional requirement.

                      ⚫

                      • It is actually a non-functional (security) requirement that can be represented by an administration use case.

                      ⚫

                      Incorrect use of use-case generalization.

                      A use-case model is not a structure chart!

                      ⚫

                      A use-case model is not a domain model!

                      ⚫

                      A use-case model is not a work of art!

                      ⚫

                      16
                      Exam weight Low

                        Think about “ Reserve Movie ” use case and fill the following table.

                        Use case name:

                        Brief description:

                        Actors:

                        Precondition postcondition

                        Actor

                        System

                        Flow of activities Exception/alternative:

                        17
                        Exam weight Low
                          Slide 18: Think about “ Reserve Movie ” use case and fill the following table.
                          Exam weight Low