Boost logo

Boost Users :

From: Robert Ramey (ramey_at_[hidden])
Date: 2006-05-15 11:37:09

Wang Yun wrote:
> Hi, all
> I do some tests and found it's ok to save/load wstring into/from
> text_oarchive, Am I very lucky? or it's safe to do this?

All archives in the serialization library include code to serialize all
"primitive" types. For purposes of this discussion, std::wstring
is considered a primitive type. In general, we have strived
to maintain archive classes independent to any particular
data type. That is - any data type should work with any archive.

> When do I need to use text_woarchive?

When you want to store using wide characters (ie unicode) rather
than multi-byte characters of a specific locale.

> Thanks,

Your welcome

Robert Ramey

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at