Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Memory stream?

Status
Not open for further replies.

jvff

Programmer
Apr 1, 2001
64
BR
Hello,
Is there a way to use some sort of memory stream like the std::fstream? This is for a normal, (almost) plain Win32 Console app. ThanX in advance.

ThanQ, ;-)

JVFF (Janito Vaqueiro Ferreira Filho)
 
The following is from my MSDN library CD's:

strstreambuf
#include <strstrea.h>

The strstreambuf class is a derived class of streambuf that manages an in-memory character array.

The file stream classes, ostrstream, istrstream, and strstream, use strstreambuf member functions to fetch and store characters. Some of these member functions are virtual functions defined for the streambuf class.

The reserve area, put area, and get area were introduced in the streambuf class description. For strsteambuf objects, the put area is the same as the get area, but the get pointer and the put pointer move independently.

Construction/Destruction — Public Members

strstreambuf

Constructs a strstreambuf object.

~strstreambuf

Destroys a strstreambuf object.

Other Functions — Public Members

freeze

Freezes a stream.

str

Returns a pointer to the string.

Stream Buffer Classes



'We all must do the hard bits so when we get bit we know where to bite' :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top