© Carleton DiLeo, Peter Cooper 2021
C. DiLeo, P. CooperBeginning Ruby 3https://doi.org/10.1007/978-1-4842-6324-2_6

6. Classes, Objects, and Modules

Carleton DiLeo1   and Peter Cooper2
(1)
Boulder, CO, USA
(2)
Louth, UK
 

In Chapter 2, we dived straight into the principles of object orientation, the method of representing concepts in Ruby by using classes and objects. Since then, we’ve looked at Ruby’s standard classes, such as String and Array, worked with them, and then branched off to look at Ruby’s logic and other core features.

In this chapter, the focus is back onto object orientation, but rather than looking at the concepts from afar, we’ll be getting into the details. We’ll look at why classes and objects behave the way they do, why object orientation ...

Get Beginning Ruby 3: From Beginner to Pro 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.