Summary

In this chapter, we've covered some patterns that identify common communication patterns between objects.

We covered how the Observer pattern can be used to update observers on the status of a given subject. Additionally, we learned how the standard PHP library contains functionality that can help us with this.

We then went on to cover how we can implement iterators in many different ways in PHP, using various interfaces in the PHP core alongside utilizing the generator function.

We went on to discuss how the Template pattern can define an algorithm skeleton that we can dynamically adapt in a more stringent way than standard polymorphism. We covered the Chain of Responsibility pattern, which allows us link together objects in a chain to execute ...

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.