April 2022
Intermediate to advanced
1012 pages
38h 1m
English
Objectives
In this chapter, you’ll:
Use traditional and modern inheritance idioms, and understand base classes and derived classes.
Understand the order in which C++ calls constructors and destructors in inheritance hierarchies.
See how runtime polymorphism can make programming more convenient and systems more easily extensible.
Use override to tell the compiler that a derived-class function overrides a base-class virtual function.
Use final at the end of a function’s prototype to indicate that function may not be overridden.
Use final after a class’s name in its definition to indicate that a class cannot be a base class.
Perform inheritance with abstract and concrete classes.
See how C++ can implement ...