Boost logo

Boost Users :

From: Robert Ramey (ramey_at_[hidden])
Date: 2005-12-12 23:25:12


> Yes thats ok, but I was serializing more than one map in the same
> class and I wanted to maintain the separation in xml. I guess I'd
> have to derive my own map I lazily trying to avoid that.

Oh then maybe you want:

void serialize(boost::archive::xml_oarchive & ar, std::map<my_class> > & t,
const
unsigned int version){
    // for each member in the map
         ar & *it;
}
void serialize(boost::archive::xml_iarchive & ar, std::map<my_class> > & t,
const
unsigned int version){
    // for each member in the map
         ar & *it;
}

which would handle xml serializations differently

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