title: Unimplemented Pure Virtual Method?
body: <p>Here is the problem: I keep getting the unimplemented pure virtual method error when trying to compile.  I have implemented all of the pure virtual methods in the abstract base class. Any ideas?</p>
  
  <p>here is the abstract base class:</p>
  
  <pre><code>class record{
  public:
      virtual int getID()=0;
      virtual record *clone(); 
  };
  </code></pre>
  
  <p>and the implementation:</p>
  
  <pre><code>class sdata: public record{
  public:
      sdata(std::string s = ""){data=s; ID=atoi(data.substr(0,8).c_str());}
      virtual int getID(){return ID;}
  private:
      std::string data;
      int ID;
  };
  </code></pre>
  
  <p>sorry, here is the complete error message:</p>
  
  <p>Unimplemented pure virtual method 'getID' in 'record'</p>
  
  <p>Perhaps this bit of code is causing the error then:</p>
  
  <pre><code>int hashTable::hash(record *x) {
     return floor(m * (x-&gt;getID() * A - floor(x-&gt;getID() * A)));
  }
  </code></pre>