C++ Stream Classes

Class Name and Contents:  


-> ios (General I/O stream class):
  • Contains basic facilities that are used by all other input and output classes.
  • Also contains a pointer to a buffer object.
  • Declare constants and functions that are necessary for handling formatted input and output functions.

-> istream ( Input stream):
  • Inherits the properties of ios.
  • Declares input functions such as get(), gettime() and read().
  • Contains overloaded extraction operator >>.

-> ostream (Output stream):
  • Inherits the properties of ios.
  • Declares input functions such as put() and write().
  • Contains overloaded extraction operator <<.

-> iostream (I/O stream):
  • Inherits the properties of ios, istream and ostream through multiple inheritance and thus contains all the input and output functions.

-> streambuf :
  • Provides an interface to physical devices through buffers.
  • Acts as a base for filebuf class used ios files.