14.7. References

Jay Fields has a nice online discussion of eval and bindings at http://blog.jayfields.com/2006/07/ruby-eval-with-binding.html. There's an interesting discussion about the benefits and dangers of monkey patching anchored around Chad Fowler's post www.chadfowler.com/index.cgi/Computing/Programming/Ruby/TheVirtuesOfMonkeyPatching.rdoc,v.

One of the best general overviews of Ruby metaprogramming and singleton classes is provided by the Ruby programmer known as "why the lucky stiff" at http://whytheluckystiff.net/articles/seeingMetaclassesClearly.html. (My only quibble is with why's naming conventions, which differ from what I used in this book.)

A plugin called Acts As Taggable On Steroids (or AATOS) was the basis for much of the discussion on plugin structure. Its home page is http://agilewebdevelopment.com/plugins/acts_as_taggable_on_steroids.

I want to acknowledge Dave Thomas's excellent talk on Metaprogramming from The Rails Edge in August 2007. It wasn't a direct influence on this chapter (and the slides are, sadly, not online), but it was a great overview of metaprogramming and a strong defense of using that part of Ruby's toolkit. Plus, it contained the quote, "The key to metaprogramming is understanding self. Isn't that also the key to life?"

Get Professional Ruby on Rails™ now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.