Rev | Line | |
---|
[857] | 1 | #ifndef BOOST_ARCHIVE_BASIC_SERIALIZER_HPP
|
---|
| 2 | #define BOOST_ARCHIVE_BASIC_SERIALIZER_HPP
|
---|
| 3 |
|
---|
| 4 | // MS compatible compilers support #pragma once
|
---|
| 5 | #if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
---|
| 6 | # pragma once
|
---|
| 7 | #endif
|
---|
| 8 |
|
---|
| 9 | /////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8
|
---|
| 10 | // basic_serializer.hpp: extenstion of type_info required for serialization.
|
---|
| 11 |
|
---|
| 12 | // (C) Copyright 2002 Robert Ramey - http://www.rrsd.com .
|
---|
| 13 | // Use, modification and distribution is subject to the Boost Software
|
---|
| 14 | // License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
---|
| 15 | // http://www.boost.org/LICENSE_1_0.txt)
|
---|
| 16 |
|
---|
| 17 | // See http://www.boost.org for updates, documentation, and revision history.
|
---|
| 18 |
|
---|
| 19 | #include <cassert>
|
---|
| 20 |
|
---|
| 21 | #include <boost/noncopyable.hpp>
|
---|
| 22 | #include <boost/config.hpp>
|
---|
| 23 | #include <boost/serialization/extended_type_info.hpp>
|
---|
| 24 |
|
---|
| 25 | namespace boost {
|
---|
| 26 | namespace archive {
|
---|
| 27 | namespace detail {
|
---|
| 28 |
|
---|
| 29 | class basic_serializer : private boost::noncopyable
|
---|
| 30 | {
|
---|
| 31 | const boost::serialization::extended_type_info & m_eti;
|
---|
| 32 | protected:
|
---|
| 33 | explicit basic_serializer(
|
---|
| 34 | const boost::serialization::extended_type_info & eti
|
---|
| 35 | ) :
|
---|
| 36 | m_eti(eti)
|
---|
| 37 | {}
|
---|
| 38 | public:
|
---|
| 39 | const boost::serialization::extended_type_info & get_eti() const {
|
---|
| 40 | return m_eti;
|
---|
| 41 | }
|
---|
| 42 | bool operator<(const basic_serializer & rhs) const {
|
---|
| 43 | return & m_eti < & rhs.get_eti();
|
---|
| 44 | }
|
---|
| 45 | };
|
---|
| 46 |
|
---|
| 47 | } // namespace detail
|
---|
| 48 | } // namespace archive
|
---|
| 49 | } // namespace boost
|
---|
| 50 |
|
---|
| 51 | #endif // BOOST_ARCHIVE_BASIC_SERIALIZER_HPP
|
---|
Note: See
TracBrowser
for help on using the repository browser.