home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Source Code 1994 March
/
Source_Code_CD-ROM_Walnut_Creek_March_1994.iso
/
win3
/
patches
/
symantec
/
rtlinc.exe
/
STDIOSTR.H
< prev
next >
Wrap
C/C++ Source or Header
|
1993-06-15
|
794b
|
44 lines
#ifndef __STDIOSTR_H
#define __STDIOSTR_H
#include <stdio.h>
#include <iostream.h>
#pragma pack(__DEFALIGN)
class stdiobuf : public streambuf {
public:
stdiobuf(FILE*);
FILE* stdiofile() { return fp; }
~stdiobuf();
int underflow();
#if __SC__ > 0x214
int overflow(int=EOF);
#else
int overflow(int);
#endif
int pbackfail(int);
private:
FILE* fp;
char *gptr_;
char *egptr_;
// Save old gptr() & egptr() while using the
// pushback buffer.
char pushback_buf[4];
int fillbuf();
};
class stdiostream : public ios {
public:
stdiostream(FILE*);
~stdiostream();
stdiobuf* rdbuf() { return &buffer; }
private:
stdiobuf buffer;
};
#pragma pack()
#endif