Filebuf
Both libraries contain a
filebuf
class for using streams to do
I/O.
It is declared in
fstream.h
in the iostream library.
The stream library had constructors that implied the use of
filebufs.
In the iostream library these constructors are replaced by constructors
of certain derived classes.
The old usage:
int fd ;
istream in(fd) ; // file descriptor
ostream out(fd) ; // file descriptor
is replaced by:
int fd ;
ifstream in(fd) ; // file descriptor
ofstream out(fd) ; // file descriptor
The optional extra arguments of the stream constructors (for specifying
whitespace skipping and ``tying``) are not supported.
The equivalent functionality is supported by format state variables.
Next topic:
Interactions with stdio
Previous topic:
Incore formatting
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 27 April 2004