Objects That Read And Write Themselves


  • Sometimes it makes sense to let each member of a class read and write itself to a file.
  • In this example you can add member functions diskout ( ) and diskin () to the person class. These functions allow a person object to write itself to a disk and read itself back in.

Positioning File Pointers<< Previous
Next >> I/O Manipulators

Our aim is to provide information to the knowledge seekers. 


comments powered by Disqus




Footer1