Wednesday, February 17, 2010

C++ Static Functions

C++ Static Functions

Static member functions have a class scope and they do not have access to the 'this' pointer of the class. When a member is declared as static, a static member of class, it has only one data for the entire class even though there are many objects created forthe class. The main usage of static function is when the programmer wants to have a function which is accessible even when the class is not instantiated.

No comments: