How does your design achieve testability?

5 Your Task
Design and implement this system, providing the following:
(a) Your design, expressed in UML, containing all significant classes, class relationships,
and significant methods and fields.
(b) Your complete, well-documented code, in Java, C++ or Python (your choice). Do
not use any third-party code without approval, in writing, from the lecturer.
Provide clear instructions for compiling and running your code.
Then, in 1�2 pages total, discuss the following issues:
(c) Where have you used polymorphism, and why? Discuss any design patterns
you�ve used that incorporate polymorphism.
(d) How does your design achieve testability? That is, what have you done to make
unit testing easier?
(e) Discuss two plausible alternative design choices, and explain their pros and cons.
(To do well here, show that you understand the range of possible solutions and
their trade-offs. If you simply say �I could have used pattern Y instead of X�, you
will get zero marks.)

Further description of the assignment:
A few questions have been coming up around the OOSE assignment, so I’ll try to put them to rest (though I’m sure there’ll be more!):

1. All the buy/sell decisions listed in the plan file are specifically related to the primary company. Only the primary company ever buys anything. Other companies can sell property, but only in conjunction with the primary company choosing to buy it. (The primary company can sell things to an “unnamed buyer”.)

2. A company owned by another company can still have its own property. When the primary company buys, say, Company X, Company X still remains the owner of whatever it originally owned. You will have to read the spec carefully to see how profit is transferred from a company to its owning company.

3. If Company X owns Company Y, then the profit calculation for Company X, for any given year, will rely on first knowing Company Y’s profit for that year. You can’t just calculate them in any order.

4. (This could have been made clearer.) In the property file, a property is always listed before whatever it owns (if anything). Or, equivalently, a property is always listed after its owner (if it has a named owner). Otherwise the file should be considered invalid.

Finally, some general advice: a pattern that looks like a good idea at first may turn out not to be after all, in a particular situation. Don’t try to force a pattern into a situation that doesn’t actually benefit from it — this will lose you marks! The marking guide will mostly be looking at whether you can understand and articulate different design approaches, including why a given pattern is or is not appropriate, and how to best make use of polymorphism. (Having said that, there are one or two good patterns that are applicable almost all of the time.)

It must contain Some of the Design Patterns and justify your choice:
1- iterator pattern 2- control – model view pattern 3- factory 4- composite pattern 5- decorator pattern 6- observer pattern
7- strategy pattern 8- state pattern 9- template method pattern

the code should use containerises and please refer to the book : Eric Freeman & Elisabeth Freeman (2004), Head First Design Patterns, ISBN 978-0-596-00712-6, O�Reilly.

“Get 15% discount on your first 3 orders with us” Use the following coupon FIRST15

Posted in Uncategorized