Presentation is loading. Please wait.

Presentation is loading. Please wait.

WARNING These slides are not optimized for printing or exam preparation. These are for lecture delivery only. These slides are made for PowerPoint 2010.

Similar presentations


Presentation on theme: "WARNING These slides are not optimized for printing or exam preparation. These are for lecture delivery only. These slides are made for PowerPoint 2010."— Presentation transcript:

1 WARNING These slides are not optimized for printing or exam preparation. These are for lecture delivery only. These slides are made for PowerPoint They may not show up well on other PowerPoint versions. You can download PowerPoint 2010 viewer from here.here These slides contain a lot of animations. For optimal results, watch in slideshow mode.

2 Which is the better Minesweeper design? LogicMinefield Storage LogicMinefield Storage :Logicm:Minefield:Storage mark update(m) :Storage mark update(m) :Logic mark (a)(b) get info m:Minefield

3

4

5

6 To Tighten or Loosen: What Makes a Good Component. CS2103/T, Lecture 7, Part 1, [Oct 4, 2013]

7 To Tighten or Loosen: What Makes a Good Component.

8 To Tighten or Loosen: What Makes a Good Component. Coupling Cohesion

9 Coupling

10

11

12 Component A Component B If I change B, will it require a change in A ? a) NO WAY b) It might Coupling Dependency ==

13 Component A Component B Coupling If I change B, will it require a change in A ?

14 Component A Component B Coupling If I change B, will it require a change in A ?

15 Component A Component B Coupling

16 Component A Component B If I change B, will it require a change in A? Yes, It might Reduce coupling

17 Good Component design cohesion Reduce coupling

18 cohesion

19 Does one thing and does it all Component A Component B Component C cohesion

20 Component A Window 1 Window 2 Window 3 Does one thing and does it all cohesion

21 Component A Component B Component C Does one thing and does it all cohesion

22 Component A Component B Component C Increase cohesion Does one thing and does it all cohesion

23 Good Component design Reduce coupling Increase cohesion

24 Reduce coupling Increase cohesion

25 Use these two concepts to justify design decisions.

26 LogicMinefieldStorageLogicMinefieldStorage (a)(b)

27 LogicMinefieldStorageLogicMinefieldStorage (a)(b) (2 nd attempt) Which is the better design? design2 {a|b} e.g. design2 b design2 {a|b} e.g. design2 b 77577


Download ppt "WARNING These slides are not optimized for printing or exam preparation. These are for lecture delivery only. These slides are made for PowerPoint 2010."

Similar presentations


Ads by Google