47 #ifndef _BACKWARD_STRSTREAM
48 #define _BACKWARD_STRSTREAM
57 namespace std _GLIBCXX_VISIBILITY(default)
59 _GLIBCXX_BEGIN_NAMESPACE_VERSION
63 class strstreambuf :
public basic_streambuf<char, char_traits<char> >
67 typedef char_traits<char> _Traits;
68 typedef basic_streambuf<char, _Traits> _Base;
72 explicit strstreambuf(
streamsize __initial_capacity = 0);
73 strstreambuf(
void* (*__alloc)(
size_t),
void (*__free)(
void*));
75 strstreambuf(
char* __get,
streamsize __n,
char* __put = 0) throw ();
76 strstreambuf(
signed char* __get,
streamsize __n,
signed char* __put = 0) throw ();
77 strstreambuf(
unsigned char* __get,
streamsize __n,
unsigned char* __put=0) throw ();
79 strstreambuf(const
char* __get,
streamsize __n) throw ();
80 strstreambuf(const
signed char* __get,
streamsize __n) throw ();
81 strstreambuf(const
unsigned char* __get,
streamsize __n) throw ();
83 virtual ~strstreambuf();
86 void freeze(
bool = true) throw ();
88 _GLIBCXX_PURE
int pcount() const throw ();
91 virtual int_type overflow(int_type __c = _Traits::eof());
92 virtual int_type pbackfail(int_type __c = _Traits::eof());
93 virtual int_type underflow();
94 virtual _Base* setbuf(
char* __buf,
streamsize __n);
95 virtual pos_type seekoff(off_type __off, ios_base::seekdir __dir,
96 ios_base::openmode __mode
97 = ios_base::in | ios_base::out);
98 virtual pos_type seekpos(pos_type __pos, ios_base::openmode __mode
99 = ios_base::in | ios_base::out);
103 operator=(const strstreambuf&);
105 strstreambuf(const strstreambuf&);
108 char* _M_alloc(
size_t);
112 void _M_setup(
char* __get,
char* __put,
streamsize __n) throw ();
116 void* (*_M_alloc_fun)(
size_t);
117 void (*_M_free_fun)(
void*);
121 bool _M_constant : 1;
125 class istrstream : public basic_istream<
char>
128 explicit istrstream(
char*);
129 explicit istrstream(
const char*);
132 virtual ~istrstream();
134 _GLIBCXX_CONST strstreambuf* rdbuf()
const throw ();
135 char* str() throw ();
142 class ostrstream : public basic_ostream<
char>
147 virtual ~ostrstream();
149 _GLIBCXX_CONST strstreambuf* rdbuf()
const throw ();
150 void freeze(
bool = true) throw();
151 char* str() throw ();
152 _GLIBCXX_PURE
int pcount() const throw ();
159 class strstream : public basic_iostream<
char>
163 typedef char_traits<char>::int_type
int_type;
164 typedef char_traits<char>::pos_type
pos_type;
165 typedef char_traits<char>::off_type
off_type;
169 virtual ~strstream();
171 _GLIBCXX_CONST strstreambuf* rdbuf()
const throw ();
172 void freeze(
bool = true) throw ();
173 _GLIBCXX_PURE
int pcount() const throw ();
174 char* str() throw ();
180 _GLIBCXX_END_NAMESPACE_VERSION
traits_type::int_type int_type
traits_type::pos_type pos_type
traits_type::off_type off_type
_Ios_Openmode openmode
This is a bitmask type.
static const openmode out
Open for output. Default for ofstream and fstream.
ptrdiff_t streamsize
Integral type for I/O operation counts and buffer sizes.
static const openmode in
Open for input. Default for ifstream and fstream.