This occurs when an object receives a message. A message is an action asking objects to behave in some way. The execution of an object- oriented program involves the receiving, interpreting and responding to messages from other objects. There are basically two ways of using inheritance. These are interface inheritance and implementation inheritance.
Implementation inheritance is a mechanism by which classes share implementation.
Interface inheritance is a classification of objects based on common external interface. A class may inherit properties and operations from an ancestor class and may have its operations inherited by other classes. Inheritance from a single direct ancestor is called single inheritance. Inheritance from multiple direct ancestors is called multiple inheritance. Class inheritance is essentially a static form of inheritance.