Top: Streams: inmemory

>     #include <pstreams.h>

>     class inmemory: instm {
>         inmemory(string mem);
>         string get/set_strdata(string);
>     }

Use inmemory to read data from a dynamic memory buffer by means of the streaming interface. Inmemory is derived from instm.

inmemory::inmemory(string mem) - constructs an inmemory object. The string passed through the mem parameter will be used by this object as a data source.

string inmemory::get/set_strdata(string) - gets or sets the memory buffer. Set_strdata() closes the stream prior to assigning the new value.

See also: iobase, instm

PTypes home