$30
CS264 - Software Design
Assignment 5
This Assignment is worth 15% of the So4ware Design CA Component.
This is an open-book, graded assignment. You may use online resources for reference purposes only
to help with the assignment. Please cite all references as comments in your submissions. You cannot
directly reuse C# solu5on code from online sources. You must not engage with another student, in
person or electronically (phone, social media, etc.) to secure assistance with this assignment. If
you do so you will receive an automa5c fail (0%). We will perform similarity checks on submiBed
assignments to check for collaboraCve efforts. A reasonable aBempt at this assignment will gain you
10% of your conCnual assignment marks. It is possible to gain extra credit (up to a maximum of 5%)
for this assignment.
Assignment 05 - So)ware Design and Design PaJern Implementa5on with C#
You are required to re-design and re-develop the console applicaCon that you developed in Assignment 02, 03 or 04. The exisCng user interface should be retained, i.e. providing simple keyboard
funcConality to (i) generate different random shapes that are added to the canvas, (ii) display the
current canvas to the console, (iii) save the canvas to a file, (iv) and implement Undo-Redo funcConality in your interacCve session (if you are re-developing Assignment 03 or 04).
Note that you do not need to implement a graphical user interface for this assignment, i.e. you are
not building a graphics app. This assignment is about designing and developing the classes and
methods associated with a typical drawing app data model and implemen5ng a So)ware Design
PaJern.
Assignment 05 - Requirements
You are required to implement the following core funcConality for this assignment:
1. You must re-design your applicaCon code so that it now uses one of the (CreaConal) Factory SoWware Design PaBerns (Factory Method or Abstract Factory) to create the shapes used in the applicaCon. You should clearly state, using comments in the code, which soWware design paBern is
being used and why. This part of the assignment is worth 7.5% of the SoWware Design CA Component.
Assignment Release Date: 07-12-2020
Submission Due Date: 18-12-2020
Feedback Due Date (esCmated): 14-01-2021 (for assignments that make Due Date)
Support Laboratories Online Labs 10-11 (Two Weeks)
Total Mark: 15%
2. You must re-design your applicaCon code so that it now uses a soWware design paBern, of your
choosing, to create style objects that are used by the shapes created by your applicaCon. When
the shapes on the canvas are drawn, ie. outpuBed as SVGs, then output methods must uClise the
style object. You should clearly state, using comments in the code, which soWware design paBern
is being used. This part of the assignment is worth 7.5% of the SoWware Design CA Component.
3. You must include a relevant class diagram (PDF format) for your parts 1 and 2 above. This should
be derived from the codebase using, for example, the automated PUML extensions for VS Code.
We will use these diagrams to compare the class structure to the soWware design paBern chosen
to implement your chosen Factory soluCons. Finally, remember to include a short note explaining
why you have chosen these soWware design paBerns, and why you think these are the correct
choice for your applicaCon.
Assignment 05 - Extra CA Credit
There is no extra credit opCon available for this assignment.
IMPORTANT SUBMISSION DETAILS
Please indicate the Opera5ng System (Linux/Windows/MacOS/Online) and IDE (e.g. VS Code) version used for tes5ng (as a comment in your submiJed code). If you use an online IDE please clearly
specify the IDE (hBp://repl.it) and provide a link where possible.
All work must be submiBed via Moodle (see "Assignments" secCon for submission). Work submiBed
via other means will not be accepted unless you have prior arrangements with the Head Demonstrator (Behnam Faghih). All work MUST be submiBed by the due-date deadline. Late submissions will
not be accepted.
The assignment submission is a zip file named “assignment-05-xxxxxxxxx.zip” (where “xxxxxxxxx” is
your student id) containing soluIon files, e.g. named “shapefactories.cs”, “Program.cs”, etc. together
with any other resources used in the assignment soluIon. Please ensure that all external files use relaIve directory referencing, rather than hard-coding the files’ locaIon.