1 #ifndef BOOST_SERIALIZATION_UNORDERED_SET_HPP
2 #define BOOST_SERIALIZATION_UNORDERED_SET_HPP
4 // MS compatible compilers support #pragma once
5 #if defined(_MSC_VER) && (_MSC_VER >= 1020)
9 /////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8
10 // unordered_set.hpp: serialization for stl unordered_set templates
12 // (C) Copyright 2002 Robert Ramey - http://www.rrsd.com .
13 // (C) Copyright 2014 Jim Bell
14 // Use, modification and distribution is subject to the Boost Software
15 // License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
16 // http://www.boost.org/LICENSE_1_0.txt)
18 // See http://www.boost.org for updates, documentation, and revision history.
20 #include <boost/config.hpp>
22 #include <unordered_set>
24 #include <boost/serialization/unordered_collections_save_imp.hpp>
25 #include <boost/serialization/unordered_collections_load_imp.hpp>
26 #include <boost/serialization/archive_input_unordered_set.hpp>
27 #include <boost/serialization/split_free.hpp>
30 namespace serialization {
41 const std::unordered_set<
42 Key, HashFcn, EqualKey, Allocator
44 const unsigned int /*file_version*/
46 boost::serialization::stl::save_unordered_collection<
48 std::unordered_set<Key, HashFcn, EqualKey, Allocator>
62 Key, HashFcn, EqualKey, Allocator
64 const unsigned int /*file_version*/
66 boost::serialization::stl::load_unordered_collection<
68 std::unordered_set<Key, HashFcn, EqualKey, Allocator>,
69 stl::archive_input_unordered_set<
72 Key, HashFcn, EqualKey, Allocator
78 // split non-intrusive serialization function member into separate
79 // non intrusive save/load member functions
87 inline void serialize(
90 Key, HashFcn, EqualKey, Allocator
92 const unsigned int file_version
94 split_free(ar, t, file_version);
107 const std::unordered_multiset<
108 Key, HashFcn, EqualKey, Allocator
110 const unsigned int /*file_version*/
112 stl::save_unordered_collection<
114 std::unordered_multiset<Key, HashFcn, EqualKey, Allocator>
127 std::unordered_multiset<
128 Key, HashFcn, EqualKey, Allocator
130 const unsigned int /*file_version*/
132 boost::serialization::stl::load_unordered_collection<
134 std::unordered_multiset<Key, HashFcn, EqualKey, Allocator>,
135 boost::serialization::stl::archive_input_unordered_multiset<
137 std::unordered_multiset<Key, HashFcn, EqualKey, Allocator>
142 // split non-intrusive serialization function member into separate
143 // non intrusive save/load member functions
151 inline void serialize(
153 std::unordered_multiset<Key, HashFcn, EqualKey, Allocator> &t,
154 const unsigned int file_version
156 boost::serialization::split_free(ar, t, file_version);
159 } // namespace serialization
162 #endif // BOOST_SERIALIZATION_UNORDERED_SET_HPP