title: @selector implementation in C++
body: <p>I need to implement similar mechanism like @selector(Objecitive-C) in C++. By googling i have found. It does not help me...</p>
  
  <pre><code>template &lt;class AnyClass&gt; 
  class ClassCallback
  {
      // pointer to member function
      void (AnyClass::*function)(void);
  
      // pointer to object
      AnyClass object;  
  public:
  
      ClassCallback()     {  }
      ~ClassCallback()    {  }
  
      ClassCallback(AnyClass _object, void(AnyClass::*_function)(void))
      : object( _object ), function( _function ) { };
  
      virtual void call(){ 
           (object-&gt;*function)();
      };
  
  };
  </code></pre>
  
  <p>Is there any different approach to implement which is similar to objective-C like</p>
  
  <pre><code>typedef struct objc_selector    *MY_SEL;  
  </code></pre>
  
  <p>Need to implement objc_selector It is abstract class in objective-C. How to implement objc_selector any idea...</p>