title: std::ostream to QDataStream
body: <p>I have overloaded '&lt;&lt;' operator for MyClass.</p>
  
  <pre><code>friend std::ostream&amp; operator &lt;&lt; (std::ostream&amp; out, const MyClass&amp; Obj);
  </code></pre>
  
  <p>Now I want to convert std::ostream to QDataStream rather than converting MyClass to QDataStream.</p>
  
  <pre><code>friend QDataStream operator &lt;&lt; (QDataStream&amp; out, std:ostream&amp;);
  </code></pre>
  
  <p>Something like this.
  Your help will be appreciated.</p>