Professional Documents
Culture Documents
3 - Inheritance
3 - Inheritance
Monday, 26 September 11
3.1 INTRODUCTION
Allows
is to specify that a class gets some of its characteristics from a parent class and then adds unique features of its own. for richer, more powerful programming. us to write less code.
Allows Allows
Monday, 26 September 11
INHERITANCE OF VEHICLES
Monday, 26 September 11
Monday, 26 September 11
Act
as a base for our class hierarchy. cannot be created from abstract classes. of animals.
Objects Example
Monday, 26 September 11
MULTIPLE INHERITANCE
Monday, 26 September 11
GUIDELINES
do
remember
that there are alternatives such as association and aggregation class should be a kind of its superclass class should be an extension of its superclass
a a
Monday, 26 September 11