Jafar
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
serialization.hpp
00001 #ifndef _JMATH_SERIALIZATION_HPP_
00002 #define _JMATH_SERIALIZATION_HPP_
00003 
00004 #include "jmath/jblas.hpp"
00005 
00006 #ifdef BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
00007 namespace boost { namespace serialization {
00008 #else
00009 namespace boost { namespace numeric { namespace ublas {
00010 #endif
00011     template<class Archive, class T, std::size_t S>
00012     inline void serialize(
00013     Archive & ar,
00014     boost::numeric::ublas::bounded_vector<T, S> &v,
00015     const unsigned int file_version
00016     ){
00017       for(int i = 0; i < S; i++)
00018       {
00019         ar & v(i);
00020       }
00021     }
00022 
00023     template<class Archive, class T, std::size_t M, std::size_t N>
00024     inline void serialize(
00025     Archive & ar,
00026     boost::numeric::ublas::bounded_matrix<T, M, N> &m,
00027     const unsigned int file_version
00028     ) {
00029       for(int i=0; i<M;i++)
00030         for(int j=0; j<N;i++)
00031           ar & m(i,j);
00032     }
00033 
00034 #ifdef BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
00035 }; };
00036 #else
00037 }; }; };
00038 #endif
00039 
00040 #endif
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Wed Oct 15 2014 00:37:21 for Jafar by doxygen 1.7.6.1
LAAS-CNRS