I have an assignment, asking:
Explain the answer to this question: "How does my design maintain low coupling?" Hint: How to maintain low coupling?
Consider a scenario where you are asked to run the program but given a completely different record structure, e.g. what would you have to change in your code if you have to sort this file (assuming you would have to order it by field number 3):
HB Pencil, premium brand pencil for drafting, 1, 1000, box of 10
ruler, metric, 2, 30, each
coloring pencils, common colours, 3, 100, box of 12
Note that it would be useful to design the code so that it can read any text file (assuming it maintains the same comma-delimited records) and sort it by any specified field. This would require additional design characteristics that we like you to think about. HINT: Consider a template or a configuration file that is required to accompany the input text file. Now put the overall design together justifying this agile ability of this software.
Submit the following: a) The answer to the question "How does my design maintain low coupling?" in reference to what was submitted in 2A. [2 pts] Enhance your answer by utilizing at least 2 other patterns for supporting low-coupling [2+2pts]
I am trying to come up with GRASP pattern class diagrams and I'm having a hard time as most of my designs have tight coupling. I would appreciate some help on how an 'information expert' and 'low coupling' design pattern would look for the above requirement as those are the ones I have attempted and failed so far.
Thank you for your help.
Aucun commentaire:
Enregistrer un commentaire