Coders' View Blog: The Strategy Pattern Using PHP

Courtesy PHPDeveloper.org  Fri, 05/29/2009 - 10:14

On the Coders' View blog there's a recent post looking at using the strategy design pattern in your PHP application.

In the strategy pattern, algorithms are extracted from complex classes so they can be replaced easily.

For example, the strategy pattern is an option if you want to change the way pages are ranked in a search engine.

Think about a search engine in several parts - one that iterates through the pages, one that ranks each...


 

More related items

Kurt Payne's Blog: How to Unit Test pcntl_fork()
Kurt Payne has a new post to his blog showing how you can unit test your process forking in your PHP application (pcntl). At some point, many php developers turn to the pcntl functions in...

Kevin Schroeder's Blog: Connecting to the Zend...
Kevin Schroeder has come back around and has posted a new tutorial to his blog showing how to connect PDT to the Zend Developer Cloud (the "PHP Development Tools" extension for the Eclipse...

Bradley Holt's Blog: The Twelve-Factor App Applied to...
Recently a site called The Twelve Factor App surfaced as a guideline for web applications to be at their best. Bradley Holt has taken these suggestions and has applied them to PHP...


 

Post new comment

The content of this field is kept private and will not be shown publicly.
computer-internet.marc8.com