Chapter 4. Structural Design Patterns

Structural design patterns provide different ways to create class structure; for example, this can be how we use encapsulation to create bigger objects from smaller ones. They exist to ease the design by allowing us to identify simple ways to realize these relationships between entities.

In the last chapter, we covered how creational patterns can be used to determine how objects should be created; with structural patterns, we can determine the structure and relationship between classes.

After a brief note on Agile software architecture, in this chapter we will cover the following topics:

  • Decorator pattern
  • Class Adapter pattern
  • Object Adapter pattern
  • Flyweight pattern
  • Composite pattern
  • Bridge pattern
  • Proxy pattern

Get Mastering PHP Design Patterns now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.