views:

197

answers:

2

Reading up on design patterns, and have found that there are 23(?) some-odd patterns that have been defined. I've seen a bit of overlap in a few (ie. builder and decorator) that would suggest either

a. I don't fully understand the given patterns, and the differences between them

b. Some of the design features of a few patterns overlap with others

Shouldn't the whole philosophy of design patterns enforce the idea of pattern "orthogonality" in the set of known patterns?

+3  A: 
marcgg
A: 

There are literally an unlimited amount of design patterns though 23 defined by the gang of four (GO4). You could roll your own and call it Janie if you wanted ... if people adopt it then it is in fact a design pattern. Depending on the technology mix you could use n number of patterns at a time.

Here is a good source to learn patterns within the context of the .NET world (it's $99 but invaluable):

http://www.dofactory.com/Default.aspx

As for overlap ... not really ... a good example would be MVC (Model View Controller). Effectively it's implemented in dozens of ways such as CakePHP, ASP.NET MVC, Spring, Struts, etc. however it has a close relative called MVP (Model View Presenter) which never the two will meet; they share many aspects (the Model View portion) however have clear differences.

On any given development project you can use dozens of Design Patterns. E.g. Repository Pattern, MVC, Decorator, etc. etc.

Nissan Fan