Friday, February 19, 2010

Inheritance .

In any inheritance Private members are not inherited .

Public Inheritance : things will come as it is , Protect base-->Protected deirved , Public base--> Public derived .

Private Inheritance : Things will come as Private Protected base-->Private deirved , Public base--> Private derived .

Protected Inheritance : Things will come as Protected Protected base -->Protected deirved , Public base--> Protected derived .

Virtual Inheritance : used in multiple and multilevel Inheritance to solve "THe famous Diamond problem "
Link : http://en.wikipedia.org/wiki/Virtual_inheritance

2 comments:

Followers