Annotation of mstools/h/stdiostr.h, revision 1.1.1.1

1.1       root        1: /***
                      2: *stdiostr.h - definitions/declarations for stdiobuf, stdiostream
                      3: *
                      4: *      Copyright (c) 1991-1992, Microsoft Corporation.  All rights reserved.
                      5: *
                      6: *Purpose:
                      7: *      This file defines the classes, values, macros, and functions
                      8: *      used by the stdiostream and stdiobuf classes.
                      9: *      [AT&T C++]
                     10: *
                     11: ****/
                     12: 
                     13: #include <iostream.h>
                     14: #include <stdio.h>
                     15: 
                     16: // Force word packing to avoid possible -Zp override
                     17: #pragma pack(4)
                     18: 
                     19: #pragma warning(disable:4505)          // disable unwanted /W4 warning
                     20: // #pragma warning(default:4505)       // use this to reenable, if necessary
                     21: 
                     22: #ifndef _INC_STDIOSTREAM
                     23: #define _INC_STDIOSTREAM
                     24: class stdiobuf : public streambuf  {
                     25: public:
                     26:        stdiobuf(FILE* f);
                     27: FILE * stdiofile() { return _str; }
                     28: 
                     29: virtual int pbackfail(int c);
                     30: virtual int overflow(int c = EOF);
                     31: virtual int underflow();
                     32: virtual streampos seekoff( streamoff, ios::seek_dir, int =ios::in|ios::out);
                     33: virtual int sync();
                     34:        ~stdiobuf();
                     35:        int setrwbuf(int _rsize, int _wsize); // CONSIDER: move to ios::
                     36: // protected:
                     37: // virtual int doallocate();
                     38: private:
                     39:        FILE * _str;
                     40: };
                     41: 
                     42: // obsolescent
                     43: class stdiostream : public iostream {  // note: spec.'d as : public IOS...
                     44: public:
                     45:        stdiostream(FILE *);
                     46:        ~stdiostream();
                     47:        stdiobuf* rdbuf() const { return (stdiobuf*) ostream::rdbuf(); }
                     48:        
                     49: private:
                     50: };
                     51: 
                     52: // Restore default packing
                     53: #pragma pack()
                     54: 
                     55: #endif         // !_INC_STDIOSTREAM

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.