Connie's Convenience Store - About Peter Coad
Connie's Convenience Store - About Peter Coad
Connie's Convenience Store - About Peter Coad
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Applying Patterns: Select and Organize Problem-Domain Objects Connie’s <strong>Convenience</strong> <strong>Store</strong> 19<br />
Participant-transaction<br />
#3. “Participant-Transaction” Pattern transaction patterns<br />
Participant<br />
number<br />
startDate<br />
endDate<br />
password<br />
authorizationLevel<br />
aboutMe<br />
howMany<br />
howMuch<br />
rankTransactions<br />
calcOverTransactions<br />
isAuthorized<br />
calcForMe<br />
n 1<br />
Transaction<br />
number<br />
date<br />
time<br />
status<br />
aboutMe<br />
calcForMe<br />
rateMe<br />
• Typical object interactions<br />
howMany —> calcForMe calcOverTransactions —> calcForMe<br />
howMuch —> calcForMe rankTransactions —> rateMe<br />
• Examples<br />
Participant: agent, applicant, buyer, cashier, clerk, client, civilian, customer, dealer,<br />
delegate, distributor, donor, employee, investor, manufacturer, member, officer,<br />
official, order clerk, owner, participant, policy holder, professional, prospect,<br />
recipient, retailer, sales clerk, sales rep, shipper, student, subscriber,<br />
supervisor, supplier, suspect, teacher, wholesaler, worker.<br />
Transaction: agreement, assignment, authorization, contract, delivery, deposit,<br />
incident, inquiry, order, payment, problem, report, purchase, refund, registration,<br />
rental, reservation, sale, shift, shipment, subscription, time charge, title,<br />
withdrawal.<br />
• Combinations<br />
actor-participant; participant-transaction; place-transaction; specific item–<br />
transaction; transaction–transaction line item; transaction–subsequent<br />
transaction.<br />
That large, numbered box with a double border is a pattern box. You’ll see these boxes<br />
from time-to-time, right when you need them, within the application chapters. The<br />
number in the upper left corner is a pattern number; it’s there for easy reference. See<br />
Chapter 7, “Strategies and Patterns Handbook,” for more.<br />
Session and its participants<br />
A session is a transaction object. What are its participants?<br />
The participants are a cashier and a register. A cashier starts a session on a specific<br />
register at a specific date and time.