I/O Forward Declarations


Typedefs

typedef basic_ios< char > std::ios
 

typedef basic_streambuf< char > std::streambuf
 

typedef basic_istream< char > std::istream
 

typedef basic_ostream< char > std::ostream
 

typedef basic_iostream< char > std::iostream
 

typedef basic_stringbuf< char > std::stringbuf
 

typedef basic_istringstream<
char > 
std::istringstream
 

typedef basic_ostringstream<
char > 
std::ostringstream
 

typedef basic_stringstream<
char > 
std::stringstream
 

typedef basic_filebuf< char > std::filebuf
 

typedef basic_ifstream< char > std::ifstream
 

typedef basic_ofstream< char > std::ofstream
 

typedef basic_fstream< char > std::fstream
 


Detailed Description

Nearly all of the I/O classes are parameterized on the type of characters they read and write. (The major exception is ios_base at the top of the hierarchy.) This is a change from pre-Standard streams, which were not templates.

For ease of use and compatibility, all of the basic_* I/O-related classes are given typedef names for both of the builtin character widths (wide and narrow). The typedefs are the same as the pre-Standard names, for example:

typedef basic_ifstream<char> ifstream;

Because properly forward-declaring these classes can be difficult, you should not do it yourself. Instead, include the <iosfwd> header, which contains only declarations of all the I/O classes as well as the typedefs. Trying to forward-declare the typedefs themselves (e.g., "class ostream;") is not valid ISO C++.

For more specific declarations, see http://gcc.gnu.org/onlinedocs/libstdc++/27_io/howto.html#10


Typedef Documentation

typedef basic_filebuf<char> std::filebuf
 

Definition at line 145 of file iosfwd.

typedef basic_fstream<char> std::fstream
 

Definition at line 148 of file iosfwd.

typedef basic_ifstream<char> std::ifstream
 

Definition at line 146 of file iosfwd.

typedef basic_ios<char> std::ios
 

Definition at line 136 of file iosfwd.

typedef basic_iostream<char> std::iostream
 

Definition at line 140 of file iosfwd.

typedef basic_istream<char> std::istream
 

Definition at line 138 of file iosfwd.

typedef basic_istringstream<char> std::istringstream
 

Definition at line 142 of file iosfwd.

typedef basic_ofstream<char> std::ofstream
 

Definition at line 147 of file iosfwd.

typedef basic_ostream<char> std::ostream
 

Definition at line 139 of file iosfwd.

typedef basic_ostringstream<char> std::ostringstream
 

Definition at line 143 of file iosfwd.

typedef basic_streambuf<char> std::streambuf
 

Definition at line 137 of file iosfwd.

typedef basic_stringbuf<char> std::stringbuf
 

Definition at line 141 of file iosfwd.

typedef basic_stringstream<char> std::stringstream
 

Definition at line 144 of file iosfwd.


Generated on Tue Jan 30 17:31:58 2007 for GNU C++ STL by doxygen 1.3.6