From 015623fe93af812328e329203f7cd844b57e5c0f Mon Sep 17 00:00:00 2001 From: Niklas Granander <nikgr117@student.liu.se> Date: Mon, 16 Sep 2019 22:56:17 +0200 Subject: [PATCH] Add readme to Task A --- Task_A/readme.md | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 Task_A/readme.md diff --git a/Task_A/readme.md b/Task_A/readme.md new file mode 100644 index 0000000..e261971 --- /dev/null +++ b/Task_A/readme.md @@ -0,0 +1,11 @@ +# Task A: The Iterator and Strategy Patterns + +In this readme, my best attempt of answering the given questions for task A of Lab 1 is presented: + +#### 1. First, you should describe which elements implement the Strategy design pattern, and relate the concepts in that design pattern to the example code given. You should be able to reason with respect to both the basic example on GitLab and the elaborate one given above. + +#### 2. Second, you should explain how the current implementation violates the principles of the Iterator design pattern (applicable to both the basic example on GitLab and the elaborate one given above) + +#### 3. Third, you should correct the implementation provided so that it works as intended. Explain why it did not work initially. + +#### 4. Fourth, you should explain how you encapsulated all objects in interfaces to enforce Interface Segregation, which states that all clients should use clientÂspecific interfaces. This assumes that all methods accessible through an interface is useable by any client. In your explanation, provide sufficient code to explain how to extend the current implementation to the elaborate functionality given in the example above, by providing interfaces between the different classes. \ No newline at end of file -- GitLab