Today, I encountered the visitor pattern in the SLD implementation inside Geotools. This is reason enough to consider this pattern in the world of Ruby. Especially because I read recently this post where visitor is supposed to be more an antipattern that a pattern. This is because Ruby supports extension of objects at runtime. Nevertheless, I need to check it out!

Recently I read here that there are GOF patterns which cannot be applied for every language (in Ruby, metaprogramming takes place so that some patterns are unnecessary). But I’m sure that factories are still sexy, no matter what programming language is used. That’s simply an intelligent way to create objects in one place instead of scatter “new Type()” everywhere in your code. That’s true for Ruby as well.

I have been learning Ruby for 2-3 months. At the beginning, I was very shocked by some approaches being used there.
Recently, I have been very excited about the powerful meta-programming features working very reliably. By the way, a few years ago, I tried to explain to people how difficult it is to deal with such dynamic languages like Javascript (and other ones as well) and how lucky Java programmers are because the have a compiler.