[serialization and asio] Trying to serialize asio IPs

Hello, my name is Eoin O'Callaghan. I wasn't sure if this email should
have been sent to ASIOs own mailing list or this Boost one, hopefully
this was an ok place.
My bit of bother is in trying to use Boost.Serialization to save some
IP addresses stored internally as Boost.ASIO asio::ip::address_v4 and
address_v6 classes. I wonder has anyone any pointers as my attempts
thus far are not getting me anywhere? The IP classes can be
constructed from, and exported to, boost::array

As far as I know, no one has written serialization functions for any of the asio classes nor for boost::array. This should be relatively straight forward however. For boost::array look at the code included for serialization of std::vector and/or for the array wrapper class in the HEAD. Robert Ramey

Robert Ramey wrote:
As far as I know, no one has written serialization functions for any of the asio classes nor for boost::array.
This should be relatively straight forward however. For boost::array look at the code included for serialization of std::vector and/or for the array wrapper class in the HEAD.
Should we consider adding serialization support for tr1::array in Boost 1.35? -- AlisdairM

Hello, thank you all for your replies. I was able to get a working solution for the asio ip classes by using their string representations.
Should we consider adding serialization support for tr1::array in Boost 1.35?
I think would be an excellent addition as t1::arrays are much nicer to work with at times. Kind regards, Eoin.
participants (3)
-
AlisdairM
-
Eoin O'Callaghan
-
Robert Ramey