title: Force derived class to implement a private method
body: <p>Is there a way, I can force a derived class to implement an interface through a private function. What I want is the following.</p>
  
  <pre><code>class base{
  private:
      virtual void do_something() = 0; // This can be private/public/protected
  };
  </code></pre>
  
  <p>The derived class MUST provide the implementation of <code>do_something()</code> which is not public. As you can guess, my objective here is to make the user give an implementation of a function but make sure that the base class is the one that will call it and an object of the <code>class derived : public base{...}</code> won't ever be able to call <code>do_something()</code> on its own?</p>
  
  <p>EDIT: Just wanted to add, the <code>class derived : base</code> will be written by the user and not by me. The use case is to make sure that functions of the base class control when do_something() is called.</p>