Use LEFT and RIGHT arrow keys to navigate between flashcards;
Use UP and DOWN arrow keys to flip the card;
H to show hint;
A reads text to speech;
11 Cards in this Set
- Front
- Back
Design Principle
Identify the aspects of your application that ____ and separate them from what stays the ____. |
Design Principle
Identify the aspects of your application that VARY and separate them from what stays the SAME. (Page 9) |
|
Design Principle
Program to an _________, not an ______________. |
Design Principle
Program to an INTERFACE, not an IMPLEMENTATION. (Page 11) |
|
Design Principle
Favor ___________ over ___________. |
Design Principle
Favor COMPOSITION over INHERITANCE. (Page 23) |
|
This pattern defines a family of algorithms, encapsulates each one, and makes them interchangeable. This pattern lets the algorithm vary independently from clients that use it.
What is this design pattern's name? |
The Strategy Pattern
(Page 24) |
|
This pattern desines a one-to-many dependence between objects so that when one object changes state, all of its dependents are notified and updated automatically.
What is this design pattern's name? |
The Observer Pattern
(Page 51) |
|
Design Principle
Strive for _______ coupled designs between objects that interact. |
Design Principle
Strive for LOOSELY coupled designs between objects that interact. (Page 53) |
|
The Observer Pattern is a combination of publishers and ___________.
|
The Observer Pattern is a combination of publishers and SUBSCRIBERS.
(Page 45) |
|
Design Principle
Classes should be open for _________, but closed for ____________. |
Design Principle
Classes should be open for EXTENSION, but closed for MODIFICATION. (Page 86) |
|
This pattern attaches additional responsibilities to an object dynamically. This pattern provides a flexible alternative to subclassing for extending functionality.
What is the name of this design pattern? |
The Decorator Pattern
(Page 91) |
|
Decorators have the same _________ as the objects they decorate.
|
Decorators have the same SUPERTYPE as the objects they decorate.
(Page 90) |
|
Decorators and ________ components don't mix.
|
Decorators and concrete components don't mix.
"If you have code that relies on the concrete component's type, decorators will break that code." (Page 99) |