| Introduction to OOP | Chapter 20: The STL : | next | previous | audio | real | text |
In C++ even the function call operator (parenthesis operator) can be overloaded. Allows for creation of objects that can be used like functions.
class biggerThanThree {
public:
bool operator () (int v)
{ return v > 3; }
};
Can be used to find the first value bigger than 3, for example.