gatotkaca | 6 Sep 18:04
Favicon

Serialization problem while using class template with template function


Dear everyone,

I need to serialize a class like this:

template<typename typename1, typename typename2=double>
		class test_mean
		{

		public:

			test_mean(){}

			typename1 typename1_type;

			typename2 typename2_type;
			
		private:
			std::vector<double> m_parameters;

			friend class boost::serialization::access;
			template<class Archive>
			void serialize(Archive & ar, const unsigned int version)
			{
				ar & boost::serialization::base_object<base_type>(*this);
				ar & m_parameters;
			}
		};

But I got trapped in the famous 'serialization trap' giving following error
(Continue reading)


Gmane