From: Enrique Comba Riepenhausen Date: 2007-05-09T15:56:01+09:00 Subject: Re: [ANN] - Ruby Patterns Hi John! Thanks for the warnings ;) Actually I am not only trying to translate the GoF patterns into Ruby, there are zillions of different patterns... "Each pattern is a three-part rule, which expresses a relation between a certain context, a problem, and a solution." as Christopher Alexander says. And I don't believe that this cases don't apply for Ruby, they just do it in a different way. If you take the creational patterns in GoF they might be differences in the implementation, but the problems still exists... I will not be disappointed ;) Ruby is powerful! But with any language in the world you can use it wrong and lose most of it's power... Cheers, Enrique Comba Riepenhausen On 9 May 2007, at 00:27, John Carter wrote: > On Tue, 8 May 2007, Enrique Comba Riepenhausen wrote: >> I come from a Java environment (have been coding in Java for the >> past 11 years) and I must admit that I was amazed by Ruby when I >> stumbled onto it not long ago. >> >> One of my hobbies has always been the study of design patterns, >> refactoring, etc... And in general the way we can improve code to >> make it more maintainable, etc. > > Be warned that several Javarish design patterns become practically > null ops in Ruby because... > * Everything in Ruby, including and especially Classes are objects. > * Everything in Ruby is open for extension at compile time. > * The Ruby module / class structure is hackable at run time. > > Thus, especially the construction patterns from the GoF practically > vanish into the background of ruby just doing what ruby does. > > So don't be disappointed when some of your Design Pattern translation > efforts seem to give trivial results, that should be make you say Wow! > Ruby is powerful! > > > John Carter Phone : (64)(3) 358 6639 > Tait Electronics Fax : (64)(3) 359 4632 > PO Box 1645 Christchurch Email : john.carter@tait.co.nz > New Zealand > >