previous | index | next

Static Methods

Regular class methods are dynamic because they are called as messages passed to objects:
     object->dynamic_method(...)

Static methods are those that are not called on objects. Instead, they are called like non-OOP C++ functions:

     static_method(...)

Static methods must be declared static in their class definitions, as in:

     static string intToString(int i);

This declaration appears in the declaration of a class called Utils.


previous | index | next