serialize_ptr_unordered_map.hpp 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. //
  2. // Boost.Pointer Container
  3. //
  4. // Copyright Thorsten Ottosen 2008. Use, modification and
  5. // distribution is subject to the Boost Software License, Version
  6. // 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  7. // http://www.boost.org/LICENSE_1_0.txt)
  8. //
  9. // For more information, see http://www.boost.org/libs/ptr_container/
  10. //
  11. #ifndef BOOST_PTR_CONTAINER_SERIALIZE_UNORDERED_PTR_MAP_HPP
  12. #define BOOST_PTR_CONTAINER_SERIALIZE_UNORDERED_PTR_MAP_HPP
  13. #include <boost/ptr_container/detail/serialize_ptr_map_adapter.hpp>
  14. #include <boost/ptr_container/ptr_unordered_map.hpp>
  15. namespace boost
  16. {
  17. namespace serialization
  18. {
  19. template<class Archive, class Key, class T, class Hash, class Pred, class CloneAllocator, class Allocator>
  20. void serialize(Archive& ar, ptr_unordered_map<Key, T, Hash, Pred, CloneAllocator, Allocator>& c, const unsigned int version)
  21. {
  22. split_free(ar, c, version);
  23. }
  24. template<class Archive, class Key, class T, class Hash, class Pred, class CloneAllocator, class Allocator>
  25. void serialize(Archive& ar, ptr_unordered_multimap<Key, T, Hash, Pred, CloneAllocator, Allocator>& c, const unsigned int version)
  26. {
  27. split_free(ar, c, version);
  28. }
  29. } // namespace serialization
  30. } // namespace boost
  31. #endif