title: How would i file handle objects(store / import) in C++
body: <pre><code>Petroleum test = Set_Petroleum_values();
      ofstream fuel("Fuel.txt");
      {
          fuel &lt;&lt; test &lt;&lt; " ";
          fuel.close();
      }
  </code></pre>
  
  <p>the set values function takes the users input and calls a default constructor for the test object.
  My <strong>aim</strong> here is to somehow save the info that is being stored into this object however i am not sure how would i overload the "&lt;&lt;" operator when it comes to file handling.
  and yes the aim is to store the object so that the info is maintained once different operations and functions are proceeded etc.</p>