22.3.  Multiple Inheritance

[ fromfile: multiple-inheritance.xml id: multiple-inheritance ]

Multiple inheritance is a form of inheritance in which a class inherits the structure and behavior of more than one base class.

Common uses of multiple inheritance:

As with single inheritance, multiple inheritance defines a static relationship among classes. It cannot be changed at runtime.

Multiple inheritance hierarchies are more complex and are harder to design, implement, and understand than single inheritance hierarchies. They can be used to solve some difficult design problems but should not not be used if a simpler approach (such as aggregation) is feasible.