Sie sind auf Seite 1von 4

Object-Oriented Analysis and Design

Total Marks : 25 Due Date : June 6, 2006

Evaluation Objectives
Ability to identify primary use cases and record them in expanded, essential form. Ability to identify outstanding concepts, associations, and attributes and record them in a conceptual model using the UML notation. Ability to identify system events and record them in a system sequence diagram using the UML notation. Ability to assign responsibilities and design collaborations between software components using the GRASP patterns, and illustrate the results in UML collaboration diagrams.

Problem Domain
Our problem domain is an information system for a video rental store. Simplifying assumptions and details:
It is a stand-alone store, not part of a larger organization. Rents only videos, not computer games or other items. A video can be in any medium: tape, DVD, and so on. The rental charge may vary by medium. For example, DVD rentals are more expensive than tapes. The store does not sell anything. For example, there are no sales of videos or food. All transactions are rentals. The input medium by which membership and video rentals are captured is not important. Cash-only payments. On completion of a rental, the customer receives a transaction report with typical information onuse your judgement. Each renter has a separate membership.

Modified form original document by Craig Larman, 1998

1. The following is the Use Case diagram of the ssytem.


Q u e ry F o r V id e o s

P a y

F in e s

R e n t V id e o s

M a n a g e M e m b e r s h ip s C le r k L o g In C u s to m e r

M a n a g e M a n a g e r M a n a g e

V id e o s A d m in is tr a t o r U s e rs

2. The textual narrative of the Rent Videos use case is given


Use Case: Rent Videos

Essential, Expanded, Conversational Style Typical Course of Events Actor Actions 1. 2. This use case begins when a Customer arrives at a checkout with videos to rent. The Customer presents their membership identification to the Clerk, who enters it into the system. For each video, the Clerk records the item identification into the system. Clerk informs Customer of total rental fee, and asks for payment. Customer pays cash to Clerk. Clerk records payment into system. 9. Generates receipt and loan report. 3. Presents membership information, and status of loans (usually nothing on loan, and no outstanding fines). Presents accumulating list of rental video titles, due dates, and total rental fee. System Response

4. 6. 7. 8.

5.

10. Clerk gives receipt and loan report to Customer, who then leaves with the rental items. Alternatives Step 3: Customer has unpaid fines. Customer must pay them before proceeding with the loan. Step 6. Customer has insufficient cash. Cancel transaction or deduct rental items until transaction can be paid for.dard Solution: Conceptual Modeling

3. Bounded by the provided Rent Videos use case, a conceptual model is created below
P a y s - fo r- o v e r d u e - c h a r g e s

V id e o R e n ta l C ashP aym ent a m o u n t : Q u a n tity 1 P a y s -fo r 1 1 d a te R e n ta lT r a n s a c tio n 1 1 1 .. * d u e D a te r e tu r n D a te re tu rn T im e

*
I n it i a t e s 1 1 C u s to m e r a d d re s s nam e phoneN um ber R e n ts - fro m R e n ts

V id e o S to re a d d re s s nam e phoneN um ber 1 M e m b e rs h ip ID s ta r tD a te 1 O w n s -a 1 C a ta lo g 1 1 D e s c rib e d -b y 1 .. * S to c k s 1 V id e o ID

1 ..* Is - r e c o r d e d - i n

* * *
1 S to ra g e M e d iu m d e s c rip tio n 1

Id e n t i fie s - r e n te r - o f

L o a n P o lic y p e rD a y R e n ta lC h a rg e p e rD a y L a te C h a rg e 1 .. * 1 D e fi n e s 1 ..*

V id e o D e s c rip tio n titl e s u b j e c tC a te g o r y D e t e r m in e s - r e n t a l- c h a r g e In flu e n c e s - c h a rg e

Your Work
(5 Marks ) Bounded by the provided Rent Videos use case, create a system sequence diagram in the UML notation. Show actors and system events. 2. (5 Marks )Write the Operation Contracts for major system events. Two such events must be confirmMembership(memberId), and recordVideoRental (videoID
1.

3. (5 Marks)Using the confirmMembership operation contract as a starting hint, complete the UML
collaboration diagram. Annotate every message with the hint GRASP (Expert, Creator, and so on) and/or other pattern that justifies it. If you add responsibilities not explicit in the contract (because you think they are important to fulfill), please briefly explain these additions.

b y C o n tr o l le r

c o n fi r m M e m b e r s h i p ( m e m b e r s h i p ID )

4.

(5 Marks)Using the recordVideoRental operation contract as a starting hint, complete the UML collaboration diagram. Annotate every message with the GRASP (Expert, Creator, and so on) and/or other pattern that justifies it. If you add responsibilities not explicit in the contract (because you think they are important to fulfill), please briefly explain these additions.

b y C o n tr o ll e r

re c o r d V id e o R e n ta l (ite m ID )

5. (5 marks) Draw a partial design class diagram, only for the VideoStore and Membership classes, based on
the standard solution collaboration diagrams and conceptual model (not based on your solutions). Show all attributes, design-phase associations (with navigability) between these two classes only, and method signatures.

Das könnte Ihnen auch gefallen