programming.nbk: Home | Index | Next Page: C++ Stream I/O | Previous Page: C++ operator overloading


 C++ polymorphism

http://www.csse.monash.edu.au/~jonmc/CSE2305/Topics/05.10.VirtualFns/html/text.html

C++ provides a simple mechanism for class¤-based polymorphism

Member functions can be marked as polymorphic using the virtual keyword

Calls to such functions then get dispatched according to the actual type of the object which owns them, rather than the apparent type of the pointer (or reference) through which they are invoked


programming.nbk: Home | Index | Next Page: C++ Stream I/O | Previous Page: C++ operator overloading


Notebook exported on Monday, 7 July 2008, 18:56:06 PM Eastern Daylight Time