comparing object identifier with string
<p>is there any possibilities to compare object identifier with string idiom without adding any member e.g. string variable variable to the class? </p>

<pre><code>struct ObjectExample {}ObEX;


string St;
cin &gt;&gt; St &gt;&gt; endl; // you enter ObEX

// What I need to reach is this comparing 
if(obEX == St)
{......}
</code></pre>

<p>As you see both object have different data type..  </p>

<h1>Edit</h1>

<p>If the comparison not possible. I would re-formalize  my question:</p>

<p>is there any technique to copy the object identifier to  a string object.</p>

<p>The whole issue is if you can NOt modify or adding the class definition but you can only create instances of it and you want to compare  a string name with the object identifier!!! </p>
