Head first - Design Patterns
You can find the source code in the github already but also you can have a look at the head first labs and learn a bit more about the book content. If you want to order a copy for you go ahead and visit O Reilly website.
Welcome to Design Patterns
The section "Welcome to Design Patterns" is a quick review through the object oriented programming and of course the paradigm inheritance X composition. Although in the end you will learn your first pattern the Strategy!
Keeping your Objects in the know
Moving on the next pattern is the Observer. And in this step of the book the author starts to give us how the patterns are applied to the real word with Java (using the java.util.Observable, but if you are looking for something in PHP you'll find the SplObserver).
Now we were introduced to the Desing Patterns in the real world with java the next pattern is the Decorator. You can find the Decorator in the java as well in the package java.io.
Baking with OO Goodness
Do you like pizza ? If yes, this is your pattern! The Factory Method Pattern come along with some pizzas store and the Dependency Inversion Principle as well.
One of a Kind Objects
Can you guess what is this pattern about ? If we are talking about just one kind of object we are talking abou Singleton Pattern.
Command Pattern !
The Adapater Patter is apresented with a good example of wall outlet from Europe and how to adapt this to another standarts such as the wall outlet from America.
But this section is not about just one pattern in Being Adaptative the book bring to us the Facade Pattern as well, with a great analogy of watching a movie at home.
Encapsulating Algorithms is all about the Template Method and how you can use it to encapsulate your algorithms
Now we have a lot of knowledge in design patterns is time to focus on collections in java such as ArrayList, Iterator Pattern and Composite Pattern! But again, if you are looking for something similar in PHP visit the SPL page.
The State of Things
Have you ever wondering about ifs and elses ? This section of the book explain to us a better way, the state pattern. From now on you will not using loads of if and else in your code to prove it the example used was a gumball machine and its states.
Controlling Object Access
We are getting to the end of the book, but first the design of this time is about security and controlling access. In our lives we present this every day in a coffee shop with our credit cards or in our work place with our credentials and in our code there is no difference and we will look at the Proxy Pattern.
Patterns of Patterns
Patterns of Patterns is much more about patterns working together instead of learning a new pattern. Often in our daily routine as programmers we combine a lot of knowledge to make a single solution. In Patterns of Patterns is the same thing we will see how to use patterns together rather than learn through them. Except for one single pattern called MVC (Design-View-Controller) you will see the MVC in details and build a great application with it.
Patterns in the Real World
Finally we have got the end ! The Patterns in the Real World is about what a patter is in fact and how it can help us to create great solutions to the client with a good code quality and maintenance. The gang of four is mentioned by the author as a reference in patterns you must check it out.