00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016 #ifndef _STLP_IOSTREAM_H
00017 # define _STLP_IOSTREAM_H
00018
00019 # ifndef _STLP_OUTERMOST_HEADER_ID
00020 # define _STLP_OUTERMOST_HEADER_ID 0x2035
00021 # include <stl/_prolog.h>
00022 # endif
00023
00024 # ifdef _STLP_OWN_IOSTREAMS
00025
00026 #ifdef __BORLANDC__
00027 # include <iostream.>
00028 #else
00029 # include <iostream>
00030 #endif
00031
00032
00033 # include <streambuf.h>
00034 # include <ostream.h>
00035 # include <istream.h>
00036
00037 # ifndef _STLP_HAS_NO_NAMESPACES
00038
00039 # ifdef _STLP_BROKEN_USING_DIRECTIVE
00040 using namespace _STLP_STD;
00041 # else
00042 using _STLP_STD::cin;
00043 using _STLP_STD::cout;
00044 using _STLP_STD::clog;
00045 using _STLP_STD::cerr;
00046 using _STLP_STD::iostream;
00047
00048 # ifndef _STLP_NO_WCHAR_T
00049 using _STLP_STD::wcin;
00050 using _STLP_STD::wcout;
00051 using _STLP_STD::wclog;
00052 using _STLP_STD::wcerr;
00053 # endif
00054
00055 # endif
00056
00057 # endif
00058
00059
00060
00061
00062 class istream_withassign : public istream {
00063 public:
00064 istream_withassign() : istream((streambuf*)0) {}
00065 ~istream_withassign() {}
00066
00067 istream_withassign& operator=(istream& __s) {
00068 ios::init(__s.rdbuf());
00069 return *this;
00070 }
00071 istream_withassign& operator=(streambuf* __s) {
00072 ios::init(__s);
00073 return *this;
00074 }
00075 };
00076
00077 class ostream_withassign : public ostream {
00078 public:
00079 ostream_withassign() : ostream((streambuf*)0) {}
00080 ~ostream_withassign() {}
00081
00082 ostream_withassign& operator=(ostream& __s) {
00083 ios::init(__s.rdbuf());
00084 return *this;
00085 }
00086 ostream_withassign& operator=(streambuf* __s) {
00087 ios::init(__s);
00088 return *this;
00089 }
00090 };
00091
00092 class iostream_withassign : public iostream {
00093 public:
00094 iostream_withassign() : iostream((streambuf*)0) {}
00095 ~iostream_withassign() {}
00096 iostream_withassign & operator=(ios& __i) {
00097 ios::init(__i.rdbuf());
00098 return *this;
00099 }
00100 iostream_withassign & operator=(streambuf* __s) {
00101 ios::init(__s);
00102 return *this;
00103 }
00104 } ;
00105
00106 # elif ! defined (_STLP_USE_NO_IOSTREAMS)
00107 # include <wrap_std/h/iostream.h>
00108 # endif
00109
00110 # if (_STLP_OUTERMOST_HEADER_ID == 0x2035)
00111 # include <stl/_epilog.h>
00112 # undef _STLP_OUTERMOST_HEADER_ID
00113 # endif
00114
00115 #endif
00116
00117
00118
00119