os/ossrv/ossrv_pub/boost_apis/boost/pending/property_serialize.hpp
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
sl@0
     1
//  (C) Copyright Jeremy Siek 2006
sl@0
     2
//  Distributed under the Boost Software License, Version 1.0. (See
sl@0
     3
//  accompanying file LICENSE_1_0.txt or copy at
sl@0
     4
//  http://www.boost.org/LICENSE_1_0.txt)
sl@0
     5
sl@0
     6
#ifndef BOOST_PROPERTY_SERIALIZE_HPP
sl@0
     7
#define BOOST_PROPERTY_SERIALIZE_HPP
sl@0
     8
sl@0
     9
#include <boost/pending/property.hpp>
sl@0
    10
sl@0
    11
#include <boost/serialization/base_object.hpp>
sl@0
    12
#include <boost/serialization/nvp.hpp>
sl@0
    13
sl@0
    14
namespace boost {
sl@0
    15
  template<class Archive>
sl@0
    16
  inline void serialize(Archive&, no_property&, const unsigned int) { }
sl@0
    17
sl@0
    18
  template<class Archive, class Tag, class T, class Base>
sl@0
    19
  void 
sl@0
    20
  serialize(Archive& ar, property<Tag, T, Base>& prop, 
sl@0
    21
            const unsigned int version) 
sl@0
    22
  {
sl@0
    23
    ar & serialization::make_nvp( "property_base" , boost::serialization::base_object<Base>(prop) );
sl@0
    24
    ar & serialization::make_nvp( "property_value" , prop.m_value );
sl@0
    25
  }
sl@0
    26
} // end namespace boost
sl@0
    27
sl@0
    28
#endif // BOOST_PROPERTY_SERIALIZE_HPP