GoConqr has a new look! Let us know what you think.

Mind map

Virtual Functions

lucy copp Advanced Programming English

Map content

Virtual Functions

  1. A member function that is dynamically bound to function calls

    • the function will dynamically assign the methd
      • Must have a virtual destructor but only needs to be in the base class
    • Can be invoked via a dereferenced pointer or reference object
  2. Polymorphism

    • function that can take arguments of different types
  3. Determination of which virtual function to use cannot always be made at run time

    • Implementation of virtual function is by virtual table
      • All the objects in a class contain one data member called virtual table pointer which points to an array of function pointers
        • When virtual pointer is envoked, actual function is determined by following the pointer and looking up the address in a table

Information

Description
Advanced Programming Mind Map on Virtual Functions, created by lucy copp on 18/05/2017.
Created by
lucy copp
Views
0
Rating

Feedback

What is it about?

What do you think of the new look?

How do you like it?