Presentation is loading. Please wait.

Presentation is loading. Please wait.

310414 REQUIREMENTS CAPTURE 1 DOMAIN MODELING EXAMPLE A video sales and rental shop would like to computerize its management of sales and rental of its.

Similar presentations


Presentation on theme: "310414 REQUIREMENTS CAPTURE 1 DOMAIN MODELING EXAMPLE A video sales and rental shop would like to computerize its management of sales and rental of its."— Presentation transcript:

1 310414 REQUIREMENTS CAPTURE 1 DOMAIN MODELING EXAMPLE A video sales and rental shop would like to computerize its management of sales and rental of its movie videos. As well, it would like to establish a presence on the Web and allow its customers to rent and buy videos via the Web. Below are the high-level requirements for a system that will manage the sale and rental of videos for the video shop: –The system must be able to keep track of which movie videos have been bought/rented and by whom. For videos bought, the system must record the quantity bought; for videos rented, the system must record which copy of the video has been rented and when it is due back. –The system must keep track of overdue rental videos and allow notices to be sent to customers who have videos overdue. –The video shop will have a customer membership option for an annual fee, which will entitle the member to discounts (10%) on video sales and rentals. –Members should be able to make reservations for movie video rentals either in person at the store, by telephone or via the Web. –A member can reserve at most five movie videos at any one time, but there is no limit on how many movie videos a member or nonmember can rent at any one time. –As an added feature, the video shop would like to allow customers (either members or nonmembers) to input, via the Web, mini-reviews (up to 100 words)

2 310414 REQUIREMENTS CAPTURE 2 DOMAIN MODELING EXAMPLE (cont’d) and a rating (from 1, lowest, to 5, highest) of movies they have rented. These reviews should be anonymous if the customer so wishes (i.e., the customer can specify whether or not he wants his name to be made known when other customers browse the reviews). –The video shop maintains the following information about all customers (members or nonmembers): name, address, phone number, fax number, age, sex, and email address. In addition, members are assigned a membership number by the video shop when they become members and a password, which allows them to access the members-only area of the video shop's web site, including accessing and changing their personal information. –Using the Web, customers should be able to buy and rent videos and browse the reviews entered by other customers. –Managers must be able to generate various reports on sales/rentals of videos. –Staff must be able to sell/rent videos from the store’s inventory and return rented videos to the store's inventory. –When selling or renting videos, staff must be able to look up customer information and determine whether the customer is a member. –An employee must be able to enter the basic information about a movie video (i.e., title, leading actor(s), director, producer, genre, synopsis, release year, running time, selling price, and rental price).

3 310414 REQUIREMENTS CAPTURE 3 DOMAIN MODELING EXAMPLE — ANALYSIS We first analyze the stated domain model requirements and then present the domain model. –The system must be able to keep track of which movie videos have been bought/rented and by whom. For videos bought, the system must record the quantity bought; for videos rented, the system must record which copy of the video has been rented and when it is due back. classes & associations: customer buys movie video; customer rents copy of movie video –>movie video has rental copy; customer rents rental copy; attributes:buys –> quantity; rental copy -> copy number, date due –The system must keep track of overdue rental videos and allow notices to be sent to customers who have videos overdue. functional requirement: no new domain model requirements in this statement –The video shop will have a customer membership option for an annual fee, which will entitle the member to discounts (10%) on video sales and rentals. generalization: member is a kind of customer

4 310414 REQUIREMENTS CAPTURE 4 DOMAIN MODELING EXAMPLE — ANALYSIS –Members should be able to make reservations for movie video rentals either in person at the store, by telephone or via the Web. classes & associations: member reserves rental copy –A member can reserve at most five movie videos at any one time, but there is no limit on how many movie videos a member or nonmember can rent at any one time. constraint:max-card(rental copy, reserves) = 5 max-card(rental copy, rents) = * –As an added feature, the video 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 5, highest) of movies they have rented. These reviews should be anonymous if the customer so wishes (i.e., the customer can specify whether or not he wants his name to be made known when other customers browse the reviews). classes & associations: customer provides review for movie video –> customer provides review; movie video has review attributes: review –> review text, rating, anonymous

5 310414 REQUIREMENTS CAPTURE 5 DOMAIN MODELING EXAMPLE — ANALYSIS –The video shop maintains the following information about all customers (members or nonmembers): name, address, phone number, fax number, age, sex, and email address. In addition, members are assigned a membership number by the video shop when they become members and a password, which allows them to access the member's only area of the video shop's web site, including accessing and changing their personal information. attributes:customer–>name, address, phone number, fax number, age, sex, email; member–>member number, password –Using the Web, customers should be able to buy and rent videos and browse the reviews entered by other customers. functional requirement: no new domain model requirements in this statement –Managers must be able to generate various reports on sales/rentals of videos. functional requirement: no new domain model requirements in this statement –Staff must be able to sell/rent videos from the store’s inventory and return rented videos to the store's inventory. functional requirement: no new domain model requirements in this statement

6 310414 REQUIREMENTS CAPTURE 6 DOMAIN MODELING EXAMPLE — ANALYSIS –When selling or renting videos, staff must be able to look up customer information and determine whether the customer is a member. functional requirement: no new domain model requirements in this statement –An employee must be able to enter the basic information about a movie video (i.e., title, leading actor(s), director, producer, genre, synopsis, release year, running time, selling price, and rental price). attributes: movie video –> title, leading actor[0..*], director, producer, genre, synopsis, release year, running time, selling price, rental price

7 310414 REQUIREMENTS CAPTURE 7 DOMAIN MODELING EXAMPLE — SOLUTION 1 Has 0..* RentsHasReview 1* Provides Reserves 1 * * * 1 * 1 0..5 0..1 Buys quantity Buys can also be a class related by two one to many associations with Customer and MovieVideo Customer Member RentalCopyMovieVideo Note that this association can only keep track of current rentals, but not of rental history since a rental copy can only be related to one customer Review can also be an association class of a many to many association between MovieVideo and Customer Review

8 310414 REQUIREMENTS CAPTURE 8 DOMAIN MODELING EXAMPLE — SOLUTION 1 Has 1* 0..* Member memberNumber password RentalCopy copyNumber dateDue Review reviewText rating anonymous MovieVideo title leadingActor [0..*] director producer genre synopsis releaseYear runningTime sellingPrice rentalPrice Customer name address phoneNumber faxNumber age sex email Rents HasReview Provides Reserves 1 * * * 1 * 1 0..5 0..1 Buys quantity

9 310414 REQUIREMENTS CAPTURE 9 DOMAIN MODELING EXAMPLE — SOLUTION 2 Has 0..* RentalHistoryHasReview 1* Provides Reserves 1 * * * 1 * * 0..5 0..1 Buys quantity ReviewCustomer Member RentalCopyMovieVideo CurrentRental * 1 CurrentRental keeps track of currently rented videos and RentalHistory keeps track all past rentals

10 310414 REQUIREMENTS CAPTURE 10 DOMAIN MODELING EXAMPLE — SOLUTION 2 Has 1* 0..* Member memberNumber password RentalCopy copyNumber dateDue Review reviewText rating anonymous MovieVideo title leadingActor [0..*] director producer genre synopsis releaseYear runningTime sellingPrice rentalPrice Customer name address phoneNumber faxNumber age sex email RentalHistory HasReview Provides Reserves 1 * * * 1 * * 0..5 0..1 Buys quantity CurrentRental * 1


Download ppt "310414 REQUIREMENTS CAPTURE 1 DOMAIN MODELING EXAMPLE A video sales and rental shop would like to computerize its management of sales and rental of its."

Similar presentations


Ads by Google