Lecture 11 - Tuesday October 19 2010. Material and some slide content from:
- GoF Design Patterns Book
Design Patterns #1 Reid Holmes Lecture 11 - Tuesday October 19 - - PowerPoint PPT Presentation
Material and some slide content from: - GoF Design Patterns Book Design Patterns #1 Reid Holmes Lecture 11 - Tuesday October 19 2010. GoF design patterns !"#$%&'()*$+,--&.*' /.&,-("*,0 1-.23-2.,0 4&5,6(".,0
Lecture 11 - Tuesday October 19 2010. Material and some slide content from:
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
!"#$%&'()*$+,--&.*' /.&,-("*,0 1-.23-2.,0 4&5,6(".,0
#,3-".7$8&-5"9 :;'-.,3-$#,3-".7 42(09&. +."-"-7<&
1(*)0&-"*
:9,<-".$=$30,'' 4.(9)& /"><"'(-& %&3".,-".
#,3,9&
:9,<-".=";?&3-
#07@&()5- +."A7
B*-&.<.&-&. /5,(*$"C$.&'<"*'(;(0(-7 /">>,*9 B-&.,-".
8&9(,-".
D&><0,-&$8&-5"9
8&>&*-" E;'&.6&. 1-,-& 1-.,-&)7 F('(-". 30,'' ";?&3-
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
a class.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
1.? 2.?
and Prototype.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
related objects without specifying their concrete classes”
WidgetFactory can provide an interface to make sure the right widget is instantiated for each platform.
products are created and represented.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
Singletons.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
convert back and forth between RTF , ASCII, and
requiring a flexible composition mechanism.
different representation.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
new parts to be appended to the existing whole.
usually vary enough that it doesn’t help much.
methods allow ConcreteBuilders to choose what methods to implement.
builds Composite objects.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
another object.”
consider an object that is expensive to populate entirely but cheap to partially populate. (e.g., remote object, large file from disk, etc.)
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
RealSubject.
Decorators add responsibilities while proxies serve as mediators.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
a whole module making it easier to use.”
subsystem.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
be used to add further decoupling.
Facade to create subsystem objects. Facades are frequently Singletons. Abstracts functionality similar to Mediator but does not concentrate on communication.
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
REID HOLMES - SE2: SOFTWARE DESIGN & ARCHITECTURE
for your system.
your system.
Explain your pattern and how it improves your system’s design.