title: C++, oop, list of classes (class types) and creating instances of them
body: <p>I have quite a lot of classes declared, all of them are inheriting from a base (kind of abstract) class ... so all of them have common methods I'd like to use ...</p>
  
  <p>now, I need to have a list of <strong>classes</strong> (<strong>not</strong> objects), later make instance of them in a loop and use the instances for calling mentioned common methods ...</p>
  
  <p>the pseudo-code</p>
  
  <pre><code>class Abstract {
   void Something();
  }
  
  class TaskOne : public Abstract {
   void Something(); // method implemented somewhere below
  }
  
  class TaskTwo : public Abstract {
   void Something(); // method implemented somewhere below
  }
  
  
  ...
  
  list&lt;Abstract&gt; lst;
  
  lst.push_back(TaskOne); // passing class type, not instance!
  lst.push_back(TaskTwo); 
  
  Abstract tmpObject = new lst[0]; //I know its wrong, just a way of expressing what I'd like to do to have instance of TaskOne!
  </code></pre>
  
  <p>please give any tips ...</p>