Boost logo

Boost :

From: Asger Alstrup Nielsen (alstrup_at_[hidden])
Date: 2002-03-01 09:30:23

> OK, but in
> template<class RW> void describe(RW & rw, X & x)
> {
> describe(rw, x.first);
> describe(rw, x.second);
> }
> you call describe() on x.first and x.second instead of
> read/write. What if x.first is a std::vector<>?

1) When saving, the number of elements is written to the stream, and
then all elements of the vector is written to the stream using
'describe' on each.

2) When loading, the number of elements is read from the stream, and
then each element is read using 'describe'.

Similar for other containers.

Please read the documentation for XTL to understand more about how this



Boost list run by bdawes at, gregod at, cpdaniel at, john at