31
Input/output library
[input.output]
31.8
String-based streams
[string.streams]
31.8.1
Header
<sstream>
synopsis
[sstream.syn]
🔗
namespace
std
{
//
[stringbuf]
, class template
basic_
stringbuf
template
<
class
charT,
class
traits
=
char_traits
<
charT
>
,
class
Allocator
=
allocator
<
charT
>
>
class
basic_stringbuf;
template
<
class
charT,
class
traits,
class
Allocator
>
void
swap
(
basic_stringbuf
<
charT, traits, Allocator
>
&
x, basic_stringbuf
<
charT, traits, Allocator
>
&
y
)
noexcept
(
noexcept
(
x
.
swap
(
y
)
)
)
;
using
stringbuf
=
basic_stringbuf
<
char
>
;
using
wstringbuf
=
basic_stringbuf
<
wchar_t
>
;
//
[istringstream]
, class template
basic_
istringstream
template
<
class
charT,
class
traits
=
char_traits
<
charT
>
,
class
Allocator
=
allocator
<
charT
>
>
class
basic_istringstream;
template
<
class
charT,
class
traits,
class
Allocator
>
void
swap
(
basic_istringstream
<
charT, traits, Allocator
>
&
x, basic_istringstream
<
charT, traits, Allocator
>
&
y
)
;
using
istringstream
=
basic_istringstream
<
char
>
;
using
wistringstream
=
basic_istringstream
<
wchar_t
>
;
//
[ostringstream]
, class template
basic_
ostringstream
template
<
class
charT,
class
traits
=
char_traits
<
charT
>
,
class
Allocator
=
allocator
<
charT
>
>
class
basic_ostringstream;
template
<
class
charT,
class
traits,
class
Allocator
>
void
swap
(
basic_ostringstream
<
charT, traits, Allocator
>
&
x, basic_ostringstream
<
charT, traits, Allocator
>
&
y
)
;
using
ostringstream
=
basic_ostringstream
<
char
>
;
using
wostringstream
=
basic_ostringstream
<
wchar_t
>
;
//
[stringstream]
, class template
basic_
stringstream
template
<
class
charT,
class
traits
=
char_traits
<
charT
>
,
class
Allocator
=
allocator
<
charT
>
>
class
basic_stringstream;
template
<
class
charT,
class
traits,
class
Allocator
>
void
swap
(
basic_stringstream
<
charT, traits, Allocator
>
&
x, basic_stringstream
<
charT, traits, Allocator
>
&
y
)
;
using
stringstream
=
basic_stringstream
<
char
>
;
using
wstringstream
=
basic_stringstream
<
wchar_t
>
;
}
1
#
The header
<sstream>
defines four class templates and eight types that associate stream buffers with objects of class
basic_
string
,
as described in
[string.
classes]
.