Nils Krumnack
There is serialization for flyweight in the sandbox. However it was implemented in a way which required changes in the base library and it's interface. I couldn't accept this. But the code is still there if anyone cares to check it out.
I might come back to you on that. I have been thinking for a while of contributing something to boost, and this would be much more manageable than a whole library.
Hi Nils, The serialization code you can find in the sandbox is probably of little use to you, since it requires deep modifications in Boost.Serialization itself that are not part of the official library. An obvious way to serialize flyweight<T> is to simply serialize their underlying T values (you'll also need to use reset_object_address if T of the tracked kind.) This has the disadvantage that when T is not tracked thatyou'll get many repetitions of the saved values, and thus big archives. The sandbox code tries to remedy this, but alas at the expense of modifications to Boost.Serialization, as mentioned above. I couldn't find a better solution, but I'd be delighted if someone finds it. Count on me for help/guidance if you decide to tackle the task. Joaquín M López Muñoz Telefónica, Investigación y Desarrollo