Boost logo

Boost Users :

Subject: Re: [Boost-users] Serialization of pointers ? --> loading notworking...
From: Simon Ruffieux (simon.ruffieux_at_[hidden])
Date: 2010-01-15 03:04:15


Thanks for your quick answer !

But the orientedPoints do work do work perfectly ! (Even without specifying
the derived class)

The problem is with the pointer to Sensor* contained in the SensorReading
class .... And it seems to me this is not a derived class ....

I'll keep trying ...

----- Original Message -----
From: "Robert Ramey" <ramey_at_[hidden]>
Newsgroups: gmane.comp.lib.boost.user
To: <boost-users_at_[hidden]>
Sent: Thursday, January 14, 2010 5:56 PM
Subject: Re: Serialization of pointers ? --> loading notworking...

> replace
> friend class boost::serialization::access;
> template <class Archive> void serialize(Archive& ar, const unsigned int
> version){
> ar & this->x & this->y & theta;
> }
>
> with something like:
> friend class boost::serialization::access;
> template <class Archive> void serialize(Archive& ar, const unsigned int
> version){
> ar & boost::serialization::base_object<?>(*this);
> }
>
> Look through the documentation and samples on how to serialize derived
> classes.
>
> Robert Ramey


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net