Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the Proxy Pattern in its eleventh chapter. Pluralsight's Design Patterns Library course has a module on the Proxy Pattern from Steve Smith. At its most basic level, the Proxy Pattern is very simple: it provides a subject interface which is implemented by both the proxy and the concrete subject. In many…
Keep Reading →
This is, of course, not ideal, since it really clutters up the pull requests and can be confusing for the person reviewing them. Luckily, it's a pretty easy fix with a few command line statements, as described in this Stack Overflow thread. Thanks for reading! I hope you find this and other articles here at ilyanaDev helpful! Be sure to follow me on Twitter @ilyanaDev.
Keep Reading →
Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the State Pattern in its tenth chapter. Pluralsight's Design Patterns Library course has a module on the State Pattern from John Brown. Some objects just behave differently in different states. A candy dispenser in an empty state will not dispense any candy, even though it would dispense candy if it…
Keep Reading →
Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the Composite Pattern in its ninth chapter. Pluralsight's Design Patterns Library course has a really informative module on the Composite Pattern from John Sonmez. Now, onto the explanation of the pattern: Part-whole hierarchies? What? In a tree structure, there are two types of elements: nodes and…
Keep Reading →
Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the Iterator Pattern in its ninth chapter. Pluralsight's Design Patterns Library course has a module on the Iterator Pattern from Steve Smith. Information hiding and encapsulation of change are pretty essential characteristics of good software. These can be tricky to adhere to, though, if your program…
Keep Reading →
Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the Template Method Pattern in its eighth chapter. Pluralsight's Design Patterns Library course has a module on the Template Method Pattern from Steve Smith, who also has a short course on the Template Method Pattern. There are all kinds of examples of real-life processes where all the steps are…
Keep Reading →
Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the Facade Pattern in its seventh chapter. Pluralsight's Design Patterns Library course has a module on the Facade Pattern from David Starr. Note: One of the great things about the Facade Pattern is that many programmers actually use it without even knowing that it has a name; it's just something that…
Keep Reading →
Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the Adapter Pattern in its seventh chapter. Pluralsight's Design Patterns Library course has a module on the Adapter Pattern from Steve Smith. Much like the power socket adapters you likely carry with you when travelling, the Adapter Pattern can be used to join two incompatible interfaces. The Adapter…
Keep Reading →
The String Calculator Kata is a great kata for practicing test-driven development. In this kata, you spend 30 minutes trying to complete as many of the 9 sections as possible, but the idea is that you never read ahead - you can only read the step you're on. You can view the instructions here. This attempt, I got through 5 sections. That's the same number as last time. I got held up with syntax of…
Keep Reading →
Head First Design Patterns by Eric Freeman and Elisabeth Freeman gives a pretty good overview of the Command Pattern in its sixth chapter. Pluralsight's Design Patterns Library course has a module on the Command Pattern from Keith Brown. In the Command Pattern, every concrete command implements a command interface, which requires implementation of an method. Because every concrete command…
Keep Reading →