I am confused about the functionality of
void operator()() const
() is the name of the operator - it's the operator that is invoked when you use
() on the object. The second
() is for the parameters, of which there are none.
Here's an example of how you would use it:
background_task task; task(); // calls background_task::operator()