More Definitions

The base class part of a derived class object is an unnamed component of the derived class object whose member variables and functions are accessible as though they were defined in the derived class so long as they are either public or protected.

The keyword protected is an access specifier. When present in a base class definition, it allows derived class functions access to members in the base class part of a derived class object while preventing access by other functions outside the base class.

Get Learning to Program in C++ 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.