<
html
>
<
head
>
<
title
>PTypes: streams: inmemory</
title
>
<
meta
http-equiv
=
"Content-Type"
content
=
"text/html; charset=iso-8859-1"
>
<
link
rel
=
"stylesheet"
href
=
"styles.css"
>
</
head
>
<
body
bgcolor
=
"#FFFFFF"
leftmargin
=
"40"
marginwidth
=
"40"
>
<
p
><
a
href
=
"../index.html"
><
img
src
=
"title-21.png"
width
=
"253"
height
=
"39"
alt
=
"C++ Portable Types Library (PTypes) Version 2.1"
border
=
"0"
></
a
>
<
hr
size
=
"1"
noshade>
<
p
class
=
"hpath"
><
a
href
=
"index.html"
>Top</
a
>: <
a
href
=
"streams.html"
>Streams</
a
>:
inmemory </
p
>
<
blockquote
>
<
pre
class
=
"lang"
>#include <
pstreams.h
>
class inmemory: instm {
inmemory(string mem);
string get/set_strdata(string);
}</
pre
>
</
blockquote
>
<
p
>Use <
span
class
=
"lang"
>inmemory</
span
> to read data from a dynamic memory buffer
by means of the streaming interface. <
span
class
=
"lang"
>Inmemory</
span
> is derived
from <
a
href
=
"streams.instm.html"
>instm</
a
>.</
p
>
<
p
><
span
class
=
"def"
>inmemory::inmemory(string mem)</
span
> - constructs an <
span
class
=
"lang"
>inmemory</
span
>
object. The string passed through the <
span
class
=
"lang"
>mem</
span
> parameter
will be used by this object as a data source.</
p
>
<
p
><
span
class
=
"def"
>string inmemory::get/set_strdata(string)</
span
> - gets or
sets the memory buffer. <
span
class
=
"lang"
>Set_strdata()</
span
> closes the stream
prior to assigning the new value.</
p
>
<
p
class
=
"seealso"
>See also: <
a
href
=
"streams.iobase.html"
>iobase</
a
>, <
a
href
=
"streams.instm.html"
>instm</
a
>
</
p
>
<
hr
size
=
"1"
>
<
a
href
=
"../index.html"
class
=
"ns"
>PTypes home</
a
>
</
body
>
</
html
>