Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(222)

Unified Diff: swig/Lib/std/std_sstream.i

Issue 553095: Checkin swig binaries for win, linux and Mac... (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/
Patch Set: '' Created 10 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « swig/Lib/std/std_set.i ('k') | swig/Lib/std/std_stack.i » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: swig/Lib/std/std_sstream.i
===================================================================
--- swig/Lib/std/std_sstream.i (revision 0)
+++ swig/Lib/std/std_sstream.i (revision 0)
@@ -0,0 +1,195 @@
+/*
+ For wchar support, you need to include the wchar.i file
+ before this file, ie:
+
+ %include <wchar.i>
+ %include <std_sstream.i>
+
+ or equivalently, just include
+
+ %include <std_wsstream.i>
+*/
+
+%include <std_alloc.i>
+%include <std_basic_string.i>
+%include <std_string.i>
+%include <std_ios.i>
+#if defined(SWIG_WCHAR)
+%include <std_wstring.i>
+#endif
+%include <std_streambuf.i>
+%include <std_iostream.i>
+
+%{
+#include <sstream>
+%}
+
+
+namespace std
+{
+ template<typename _CharT, typename _Traits = char_traits<_CharT>,
+ typename _Alloc = allocator<_CharT> >
+ class basic_stringbuf : public basic_streambuf<_CharT, _Traits>
+ {
+ public:
+ // Types:
+ typedef _CharT char_type;
+ typedef _Traits traits_type;
+// 251. basic_stringbuf missing allocator_type
+ typedef _Alloc allocator_type;
+ typedef typename traits_type::int_type int_type;
+ typedef typename traits_type::pos_type pos_type;
+ typedef typename traits_type::off_type off_type;
+
+ public:
+ // Constructors:
+ explicit
+ basic_stringbuf(ios_base::openmode __mode = ios_base::in | ios_base::out);
+
+ explicit
+ basic_stringbuf(const basic_string<_CharT, _Traits, _Alloc>& __str,
+ ios_base::openmode __mode = ios_base::in | ios_base::out);
+
+ // Get and set:
+ basic_string<_CharT, _Traits, _Alloc>
+ str() const;
+
+ void
+ str(const basic_string<_CharT, _Traits, _Alloc>& __s);
+
+ };
+
+
+ // 27.7.2 Template class basic_istringstream
+ template<typename _CharT, typename _Traits = char_traits<_CharT>,
+ typename _Alloc = allocator<_CharT> >
+ class basic_istringstream : public basic_istream<_CharT, _Traits>
+ {
+ public:
+ // Types:
+ typedef _CharT char_type;
+ typedef _Traits traits_type;
+// 251. basic_stringbuf missing allocator_type
+ typedef _Alloc allocator_type;
+ typedef typename traits_type::int_type int_type;
+ typedef typename traits_type::pos_type pos_type;
+ typedef typename traits_type::off_type off_type;
+
+
+ public:
+ // Constructors:
+ explicit
+ basic_istringstream(ios_base::openmode __mode = ios_base::in);
+
+ explicit
+ basic_istringstream(const basic_string<_CharT, _Traits, _Alloc>& __str,
+ ios_base::openmode __mode = ios_base::in);
+
+ ~basic_istringstream();
+
+ // Members:
+ basic_stringbuf<_CharT, _Traits, _Alloc>*
+ rdbuf() const;
+
+ basic_string<_CharT, _Traits, _Alloc>
+ str() const;
+
+ void
+ str(const basic_string<_CharT, _Traits, _Alloc>& __s);
+ };
+
+
+ // 27.7.3 Template class basic_ostringstream
+ template<typename _CharT, typename _Traits = char_traits<_CharT>,
+ typename _Alloc = allocator<_CharT> >
+ class basic_ostringstream : public basic_ostream<_CharT, _Traits>
+ {
+ public:
+ // Types:
+ typedef _CharT char_type;
+ typedef _Traits traits_type;
+// 251. basic_stringbuf missing allocator_type
+ typedef _Alloc allocator_type;
+ typedef typename traits_type::int_type int_type;
+ typedef typename traits_type::pos_type pos_type;
+ typedef typename traits_type::off_type off_type;
+
+
+ public:
+ // Constructors/destructor:
+ explicit
+ basic_ostringstream(ios_base::openmode __mode = ios_base::out);
+
+ explicit
+ basic_ostringstream(const basic_string<_CharT, _Traits, _Alloc>& __str,
+ ios_base::openmode __mode = ios_base::out);
+
+ ~basic_ostringstream();
+
+ // Members:
+ basic_stringbuf<_CharT, _Traits, _Alloc>*
+ rdbuf() const;
+
+ basic_string<_CharT, _Traits, _Alloc>
+ str() const;
+
+#if 0
+ void
+ str(const basic_string<_CharT, _Traits, _Alloc>& __s);
+#endif
+ };
+
+
+ // 27.7.4 Template class basic_stringstream
+ template<typename _CharT, typename _Traits = char_traits<_CharT>,
+ typename _Alloc = allocator<_CharT> >
+ class basic_stringstream : public basic_iostream<_CharT, _Traits>
+ {
+ public:
+ // Types:
+ typedef _CharT char_type;
+ typedef _Traits traits_type;
+// 251. basic_stringbuf missing allocator_type
+ typedef _Alloc allocator_type;
+ typedef typename traits_type::int_type int_type;
+ typedef typename traits_type::pos_type pos_type;
+ typedef typename traits_type::off_type off_type;
+
+ public:
+ // Constructors/destructors
+ explicit
+ basic_stringstream(ios_base::openmode __m = ios_base::out | ios_base::in);
+
+ explicit
+ basic_stringstream(const basic_string<_CharT, _Traits, _Alloc>& __str,
+ ios_base::openmode __m = ios_base::out | ios_base::in);
+
+ ~basic_stringstream();
+
+ // Members:
+ basic_stringbuf<_CharT, _Traits, _Alloc>*
+ rdbuf() const;
+
+ basic_string<_CharT, _Traits, _Alloc>
+ str() const;
+
+ void
+ str(const basic_string<_CharT, _Traits, _Alloc>& __s);
+ };
+
+
+} // namespace std
+
+
+namespace std {
+ %template(istringstream) basic_istringstream<char>;
+ %template(ostringstream) basic_ostringstream<char>;
+ %template(stringstream) basic_stringstream<char>;
+
+
+#if defined(SWIG_WCHAR)
+ %template(wistringstream) basic_istringstream<wchar_t>;
+ %template(wostringstream) basic_ostringstream<wchar_t>;
+ %template(wstringstream) basic_stringstream<wchar_t>;
+#endif
+}
« no previous file with comments | « swig/Lib/std/std_set.i ('k') | swig/Lib/std/std_stack.i » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698