[c++] Is it possible to serialize and deserialize a class in C++?

I realize this is an old post but it's one of the first that comes up when searching for c++ serialization.

I encourage anyone who has access to C++11 to take a look at cereal, a C++11 header only library for serialization that supports binary, JSON, and XML out of the box. cereal was designed to be easy to extend and use and has a similar syntax to Boost.