Mercurial > hg > vamp-build-and-test
comparison DEPENDENCIES/generic/include/boost/archive/xml_woarchive.hpp @ 101:c530137014c0
Update Boost headers (1.58.0)
author | Chris Cannam |
---|---|
date | Mon, 07 Sep 2015 11:12:49 +0100 |
parents | 2665513ce2d3 |
children |
comparison
equal
deleted
inserted
replaced
100:793467b5e61c | 101:c530137014c0 |
---|---|
1 #ifndef BOOST_ARCHIVE_XML_WOARCHIVE_HPP | 1 #ifndef BOOST_ARCHIVE_XML_WOARCHIVE_HPP |
2 #define BOOST_ARCHIVE_XML_WOARCHIVE_HPP | 2 #define BOOST_ARCHIVE_XML_WOARCHIVE_HPP |
3 | 3 |
4 // MS compatible compilers support #pragma once | 4 // MS compatible compilers support #pragma once |
5 #if defined(_MSC_VER) && (_MSC_VER >= 1020) | 5 #if defined(_MSC_VER) |
6 # pragma once | 6 # pragma once |
7 #endif | 7 #endif |
8 | 8 |
9 /////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 | 9 /////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 |
10 // xml_woarchive.hpp | 10 // xml_woarchive.hpp |
28 } // namespace std | 28 } // namespace std |
29 #endif | 29 #endif |
30 | 30 |
31 #include <ostream> | 31 #include <ostream> |
32 | 32 |
33 #include <boost/smart_ptr/scoped_ptr.hpp> | |
33 #include <boost/archive/detail/auto_link_warchive.hpp> | 34 #include <boost/archive/detail/auto_link_warchive.hpp> |
34 #include <boost/archive/basic_text_oprimitive.hpp> | 35 #include <boost/archive/basic_text_oprimitive.hpp> |
35 #include <boost/archive/basic_xml_oarchive.hpp> | 36 #include <boost/archive/basic_xml_oarchive.hpp> |
36 #include <boost/archive/detail/register_archive.hpp> | 37 #include <boost/archive/detail/register_archive.hpp> |
37 #include <boost/serialization/item_version_type.hpp> | 38 #include <boost/serialization/item_version_type.hpp> |
39 | |
40 #ifdef BOOST_NO_CXX11_HDR_CODECVT | |
41 #include <boost/archive/detail/utf8_codecvt_facet.hpp> | |
42 #else | |
43 #include <codecvt> | |
44 namespace boost { namespace archive { namespace detail { | |
45 typedef std::codecvt_utf8<wchar_t> utf8_codecvt_facet; | |
46 } } } | |
47 #endif | |
38 | 48 |
39 #include <boost/archive/detail/abi_prefix.hpp> // must be the last header | 49 #include <boost/archive/detail/abi_prefix.hpp> // must be the last header |
40 | 50 |
41 #ifdef BOOST_MSVC | 51 #ifdef BOOST_MSVC |
42 # pragma warning(push) | 52 # pragma warning(push) |
44 #endif | 54 #endif |
45 | 55 |
46 namespace boost { | 56 namespace boost { |
47 namespace archive { | 57 namespace archive { |
48 | 58 |
59 namespace detail { | |
60 template<class Archive> class interface_oarchive; | |
61 } // namespace detail | |
62 | |
49 template<class Archive> | 63 template<class Archive> |
50 class xml_woarchive_impl : | 64 class xml_woarchive_impl : |
51 public basic_text_oprimitive<std::wostream>, | 65 public basic_text_oprimitive<std::wostream>, |
52 public basic_xml_oarchive<Archive> | 66 public basic_xml_oarchive<Archive> |
53 { | 67 { |
54 #ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS | 68 #ifdef BOOST_NO_MEMBER_TEMPLATE_FRIENDS |
55 public: | 69 public: |
56 #else | 70 #else |
57 friend class detail::interface_oarchive<Archive>; | |
58 friend class basic_xml_oarchive<Archive>; | |
59 friend class save_access; | |
60 protected: | 71 protected: |
72 #if BOOST_WORKAROUND(BOOST_MSVC, < 1500) | |
73 // for some inexplicable reason insertion of "class" generates compile erro | |
74 // on msvc 7.1 | |
75 friend detail::interface_oarchive<Archive>; | |
76 friend basic_xml_oarchive<Archive>; | |
77 friend save_access; | |
78 #else | |
79 friend class detail::interface_oarchive<Archive>; | |
80 friend class basic_xml_oarchive<Archive>; | |
81 friend class save_access; | |
82 #endif | |
61 #endif | 83 #endif |
62 //void end_preamble(){ | 84 //void end_preamble(){ |
63 // basic_xml_oarchive<Archive>::end_preamble(); | 85 // basic_xml_oarchive<Archive>::end_preamble(); |
64 //} | 86 //} |
65 template<class T> | 87 template<class T> |
87 BOOST_WARCHIVE_DECL(void) | 109 BOOST_WARCHIVE_DECL(void) |
88 save(const std::wstring &ws); | 110 save(const std::wstring &ws); |
89 #endif | 111 #endif |
90 BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) | 112 BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) |
91 xml_woarchive_impl(std::wostream & os, unsigned int flags); | 113 xml_woarchive_impl(std::wostream & os, unsigned int flags); |
92 ~xml_woarchive_impl(){} | 114 BOOST_WARCHIVE_DECL(BOOST_PP_EMPTY()) |
115 ~xml_woarchive_impl(); | |
93 public: | 116 public: |
94 void | 117 void |
95 save_binary(const void *address, std::size_t count){ | 118 save_binary(const void *address, std::size_t count){ |
96 this->end_preamble(); | 119 this->end_preamble(); |
97 #if ! defined(__MWERKS__) | 120 #if ! defined(__MWERKS__) |
120 xml_woarchive_impl<xml_woarchive>(os, flags) | 143 xml_woarchive_impl<xml_woarchive>(os, flags) |
121 {} | 144 {} |
122 ~xml_woarchive(){} | 145 ~xml_woarchive(){} |
123 }; | 146 }; |
124 | 147 |
125 typedef xml_woarchive naked_xml_woarchive; | |
126 | |
127 } // namespace archive | 148 } // namespace archive |
128 } // namespace boost | 149 } // namespace boost |
129 | 150 |
130 // required by export | 151 // required by export |
131 BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::xml_woarchive) | 152 BOOST_SERIALIZATION_REGISTER_ARCHIVE(boost::archive::xml_woarchive) |