This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
notes:cprog:fall2021:projects:oop1 [2021/11/05 03:59] – [Parent-Child Relationships] hhemler | notes:cprog:fall2021:projects:oop1 [2021/11/05 04:01] (current) – [References] hhemler | ||
---|---|---|---|
Line 92: | Line 92: | ||
When something has multiple parents it is called multiple inheritance. When there is more than one tier of inheritance (grandparents) it is called multilevel inheritance. When something has multiple children it is called hierarchical inheritance. When multiple of these occur it is called hybrid inheritance. | When something has multiple parents it is called multiple inheritance. When there is more than one tier of inheritance (grandparents) it is called multilevel inheritance. When something has multiple children it is called hierarchical inheritance. When multiple of these occur it is called hybrid inheritance. | ||
+ | |||
+ | Inheritance allows us to reuse classes by having other classes inherit their members. | ||
It is possible to make a class non-subclassable (sterile) in C++ with the " | It is possible to make a class non-subclassable (sterile) in C++ with the " | ||
Line 110: | Line 112: | ||
* https:// | * https:// | ||
* https:// | * https:// | ||
- | * https:// | ||
* https:// | * https:// | ||
* https:// | * https:// |