|
Boost Users : |
From: j.c. (jolix_at_[hidden])
Date: 2008-04-18 13:01:33
const packet_base test1;
packet_base test2;
std::stringstream ss;
{
portable_binary_oarchive pboa(ss);
pboa << test1;
std::cout << "str: " << ss.str() << " size: " <<
ss.str().size() <<
std::endl;
}
{
portable_binary_iarchive pbia(ss);
pbia >> test2;
std::cout << "str: " << ss.str() << " size: " <<
ss.str().size() <<
std::endl;
}
std::stringstream ss_out;
// These are either 2 x 8 byte integers or 1 x 16 byte integer,
prob the later. Are they signed or unsigned, etc???
ss_out << ss.str()[0];
ss_out << ss.str()[1];
std::cout << "str: " << ss_out.str() << " size: " <<
ss_out.str().size() <<
std::endl;
assert(test1 == test2);
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