Chapter 14: | How to Define Classes that Inherit |
In this chapter, you learn that you can tie together classes in hierarchies such that the instance variables declared in one class automatically appear in instances belonging to another, and such that the instance methods defined in one class automatically work with target instances that belong to another. Thus, you learn about the notion of inheritance. Object-oriented programming languages provide for classes, instances, and inheritance, whereas traditional programming languages do not.