title: How to implement callbacks with interface
body: <p>I have a class which needs more callbacks..
  I am trying to implement them with an interface:</p>
  
  <pre><code>class CallbacksInterface
  {
  public:
       virtual bool mycallback1() = 0;
       virtual bool mycallback2() = 0;
       virtual bool mycallback3() = 0;
  };
  
  Class BusImplementation{
  public:
      addRequest(bool (CallbacksInterface::*callback)());
  
  }
  </code></pre>
  
  <p>Callback is parameter for <strong>addRequest()</strong> method and is defined as <strong>pointer to interface method</strong>.
  So I want to add request..</p>
  
  <pre><code>//class with callbacks
  class Main:CallbacksInterface{
  public:
        bool mycallback1(){..};
        bool mycallback2(){..};
        bool mycallback3(){..};
        //.. 
  }
  
  BusImplemantation bus;
  Main main;   
  
  bus.addRequest(main.mycallback1);          
  bus.addRequest(main.mycallback2);
  bus.addRequest(main.mycallback3);
  </code></pre>
  
  <p>But I cant pass a callback into my BusImplemantation class</p>
  
  <pre><code>error: argument of type 'bool (Main::)()' does not match 'bool (CallbacksInterface::*)()'
  </code></pre>
  
  <p>I think there is a solution with templates, but I am programming embedded devices and my compiler is limited. </p>