File indexing completed on 2025-01-18 09:28:27
0001 #ifndef BOOST_ARCHIVE_BASIC_SERIALIZER_HPP
0002 #define BOOST_ARCHIVE_BASIC_SERIALIZER_HPP
0003
0004
0005 #if defined(_MSC_VER)
0006 # pragma once
0007 #endif
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019 #include <boost/assert.hpp>
0020 #include <cstddef> // NULL
0021
0022 #include <boost/noncopyable.hpp>
0023 #include <boost/config.hpp>
0024 #include <boost/serialization/extended_type_info.hpp>
0025
0026 #ifdef BOOST_MSVC
0027 # pragma warning(push)
0028 # pragma warning(disable : 4511 4512)
0029 #endif
0030
0031 namespace boost {
0032 namespace archive {
0033 namespace detail {
0034
0035 class basic_serializer :
0036 private boost::noncopyable
0037 {
0038 const boost::serialization::extended_type_info * m_eti;
0039 protected:
0040 explicit basic_serializer(
0041 const boost::serialization::extended_type_info & eti
0042 ) :
0043 m_eti(& eti)
0044 {}
0045 public:
0046 inline bool
0047 operator<(const basic_serializer & rhs) const {
0048
0049
0050
0051
0052 return get_eti() < rhs.get_eti();
0053 }
0054 const char * get_debug_info() const {
0055 return m_eti->get_debug_info();
0056 }
0057 const boost::serialization::extended_type_info & get_eti() const {
0058 return * m_eti;
0059 }
0060 };
0061
0062 class basic_serializer_arg : public basic_serializer {
0063 public:
0064 basic_serializer_arg(const serialization::extended_type_info & eti) :
0065 basic_serializer(eti)
0066 {}
0067 };
0068
0069 }
0070 }
0071 }
0072
0073 #ifdef BOOST_MSVC
0074 #pragma warning(pop)
0075 #endif
0076
0077 #endif