20.02.2013 Views

Connie's Convenience Store - About Peter Coad

Connie's Convenience Store - About Peter Coad

Connie's Convenience Store - About Peter Coad

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

18 Connie’s <strong>Convenience</strong> <strong>Store</strong> Applying Patterns: Select and Organize Problem-Domain Objects<br />

ProblemDomain<br />

Cash<br />

CashDrawer<br />

Cashier<br />

Charge<br />

Check<br />

Item<br />

Payment<br />

Person<br />

Register<br />

Sale<br />

SaleLineItem<br />

Session<br />

<strong>Store</strong><br />

TaxCategory<br />

Sale<br />

SaleLineItem<br />

Session<br />

Figure 1–8: Select transactions.<br />

Payment<br />

APPLYING PATTERNS: SELECT AND ORGANIZE PROBLEM-DOMAIN OBJECTS<br />

You’ve selected a number of objects (and formed classes of them).<br />

Now, take an initial look at some patterns. An object-model pattern is a template of<br />

objects with stereotypical responsibilities and interactions; the template may be applied<br />

again and again by analogy.<br />

Use some patterns, initially, at this point, just to connect some of the pieces together<br />

in a meaningful way. You might discover some additional objects along the way, too.<br />

Cash<br />

Check<br />

Charge

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!