A design pattern ...
PART 1. STRUCTURAL DESIGN PATTERNS | |
Program 01. Use Bridge Design Pattern for Drawing API.
....
|
Code: Sphere.java Program output |
Program 02. Use Bridge Design Pattern for Customized List.
....
|
Code: Sphere.java Program output |
Program 03. Use Adapter Design Pattern for Link to Legacy Code.
....
|
Code: Sphere.java Program output |
Program 04. Use Adapter Design Pattern for a Requirements Table.
See: ence200.d/java.d/design-pattern-composite1.d/
|
Code: Sphere.java Program output |
Program 05. Table Adapter Model for Dynamic Display of Stock Market Quotes
See: ence200.d/java.d/design-pattern-adapter2.d ... etc.
|
Code: Sphere.java Program output |
Program 06. Create Composite Hierarchy of Shapes
See: ence200.d/java.d/design-pattern-composite2.d ... etc.
|
Code: Sphere.java Program output |
Program 07. Use Composite Hierarchy Pattern for Furniture Layout
See: ence200.d/java.d/design-pattern-composite1.d/
|
Code: Sphere.java Program output |
PART 2. BEHAVIORAL DESIGN PATTERNS |
PROGRAM OUTPUT AND SOURCE CODE |
Program 08. Mediator Design Pattern.
....
|
Standalone Program:
Peace.java Program Output: output |
Program 09. Observer Design Pattern.
....
|
Standalone Program:
Peace.java Program Output: output |
Program 10. Observer Design Pattern implemented across Threads
....
|
Standalone Program:
Peace.java Program Output: output |
PART 3. SYSTEM DESIGN PATTERNS | |
Program 11. Simple Implementation of Model-View-Controller (MVC)
....
|
Code: Sphere.java Program output |
Program 12. Mediator Implementation of Model-View-Controller (MVC)
....
|
Code: Sphere.java Program output |
Program 13. MVC Implementation of Temperature
....
|
Code: Sphere.java Program output |
PART 4. COMPONENT AND SYSTEM FACTORY DESIGN PATTERNS |
PROGRAM OUTPUT AND SOURCE CODE |
Program 14. A Simple Factory.
Here we present code for a simple factory .....
|
Code: ... Program ... |
Program 15. A Simplified Component Factory.
Here we present code for a factory of components that can be
connected via ports and relationships.
|
Code: ... Program ... |
Program 16. Abstract Factory Pattern.
An abstract factory pattern .....
![]() Figure 15. Relationship among concrete and interface classes in an abstract factory setup.
|
Code: ... Program ... |
REFERENCES
Last Modified in April 2012 by Mark Austin
Department of Civil and Environmental Engineering, University of Maryland