Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Zortech C++ 3.0r4 - <b>ostream_withassign::operator=</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
ostream_withassign::operator=

Usage

   #include <iostream.hpp>
   ostream_withassign &operator=(ostream &);
   ostream_withassign &operator=(streambuf *);

Description

   An ostream_withassign object can be can have either another ostream  type
   object, or a streambuf pointer assigned to it.

   When assignment is from an ostream, the state variables of the ostream
   assigned from are inherited unchanged. When from a streambuf, the state
   of the ostream_withasssign is the default state.

Example 

   ostream_withassign cout2;
   cout2 = cout;
   int i;
   cout2 << i;     // same as output to cout

   ostream_withassign cout3;
   cout3 = cout.rdbuf();
   cout3 << i;     // same as output to cout

Return Value

   Assignment operators return a reference to the object assigned to.




Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson