Chapter 11. OOP and Dynamic Features in Ruby

Of his quick objects hath the mind no part, Nor his own vision holds what it doth catch...

—William Shakespeare, “Sonnet 113”

This is an unusual chapter. Whereas many of the chapters in this book deal with a specific problem subdomain such as strings or files, this one doesn’t. If the “problem space” is viewed as stretching out on one axis of a graph, this chapter extends out on the other axis, encompassing a slice of each of the other areas. This is because object-oriented programming and dynamicity aren’t problem domains themselves but are paradigms that can be applied to any problem, whether it be system administration, low-level networking, or web development.

For this reason, much of this chapter’s ...

Get The Ruby Way: Solutions and Techniques in Ruby Programming, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.