|
Boost Users : |
From: Joseph Turian (turian_at_[hidden])
Date: 2006-01-16 15:33:13
Hi,
If see from the serialization documentation that if I serialize a
pointer more than once, only one instance will appear in the archive.
However, what about static member variables?
Will they only be serialized once, even if I serialize multiple
objects of the class type?
e.g.
class foo {
private:
int i;
static int j;
friend class boost::serialization::access;
template<class Archive> void serialize(Archive& ar, const unsigned
int version) {
ar & i;
ar & j; // Will j be serialized multiple times, i.e. once per
foo instance?
}
};
Thanks,
Joseph
-- http://www.cs.nyu.edu/~turian/
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