Chapter 1: Object-Oriented Programming — What’s It All About?
In This Chapter
Reviewing the basics of object-oriented programming
Getting a handle on abstraction and classification
Understanding why object-oriented programming is important
This chapter answers the two-pronged musical question: “What are the concepts behind object-oriented programming, and how do they differ from the procedural concepts covered in Book I?”
Object-Oriented Concept #1: Abstraction
Sometimes, when my son and I are watching football, I whip up a terribly unhealthy batch of nachos. I dump chips on a plate, throw on some beans and cheese and lots of jalapeños, and nuke the whole mess in the microwave oven for a few minutes.
To use my microwave, I open the door, throw in the plate of food, and punch a few buttons on the front. After a few minutes, the nachos are done. (I try not to stand in front of the microwave while it’s working, lest my eyes start glowing in the dark.)
Now think for a minute about all the things I don’t do in order to use my microwave. I don’t
Rewire or change anything inside the microwave ...