Introduction to OOP
Chapter 8: Inheritance and Substitution:
Summary of Forms of Inheritance
. The child class is a special case of the parent class; in other words, the child class is a subtype of the parent class.
. The parent class defines behavior that is implemented in the child class but not in the parent class.
. The child class makes use of the behavior provided by the parent class, but is not a subtype of the parent class.
. The child class modifies or overrides some of the methods of the parent class.
. The child class adds new functionality to the parent class, but does not change any inherited behavior.
. The child class restricts the use of some of the behavior inherited from the parent class.
. The child class and parent class are variants of each other, and the class-subclass relationship is arbitrary.
. The child class inherits features from more than one parent class. This is multiple inheritance and will be the subject of a later chapter.
, Slide 22