title: c++ Difference between two vector<MyType*> A and B based on a string member
body: <p>I've got two vector objects called A and B. The MyType class <strong>does not</strong> have a field ID and I want to get the MyType* which are in A but not in B. </p>
  
  <p>Since I do not have an ID need to compare based on the string field.</p>
  
  <p>My object's class looks like this</p>
  
  <pre><code> class Object 
      {
         public:
                 Object();
         string      Name;
         bool        Mode;
         string      something;
         Int         range;
      }
  
  
      vector&lt;Object*&gt; a; //asssume filled with objects
      vector&lt;Object*&gt; b; //asssume filled with objects
      vector&lt;Object*&gt; ret; 
  </code></pre>
  
  <p>Now I want to get diff of <code>(a,b)</code> - all the members that are in a and not b.</p>
  
  <p>How to proceed on this. I tries using <code>strcmp()</code> to do the comparison but it is not working. </p>