June 2014
Intermediate to advanced
536 pages
15h 18m
English
This chapter covers
This chapter will introduce you to a Ruby construct that’s closely related to classes: modules. As their name suggests, modules encourage modular design: program design that breaks large components into smaller ones and lets you mix and match object behaviors.
Like classes, modules are bundles of methods and constants. Unlike classes, modules don’t have instances; instead, you specify that you want to add the functionality of a particular module to that of a class or of a specific object.
It’s no accident ...
Read now
Unlock full access