???????????·????????????C++???????л?????????????????????Boost serialization??Google protobuf???????ù????????????????ü????о????????????????????
????cereal????
????cereal???????????BSD License????????????????C++11?????????????????????????????C++???л??????????????????????????л?????????????????????????XML?????JSON??cereal???????????????????????????——???????????????????????????????????????????????????????á?
????cereal???????????????????????л???cereal????????к?????????cereal????????????????????????????????л???????Boost??????????????ж????????????????????????????(raw pointer)??????????????????????std::shared_ptr??std??::unique_ptr?????????????
????cereal?????????C++11?????????????
????cereal??????ЩC++11?????????????????????????????C++??????????????????????????????????????g++4.7.3??clang++3.3??MSVC2013????????°汾??
??????????????????汾??????????????????????????????????g++??clang++?????????cereal?????libstdc++??libc++??
????cereal?????????????????
?????????????????У?cereal?????Boost?????л?????????????????????????????????????????????С?????cereal?????C++?е??????XML??JSON??????????????
????cereal????????
????cereal?????????????л????????????????XML??JSON???л?????
????cereal??????????Boost????????????????????? ????????????????cereal??????????????????????????????л??浵???????
????cereal??????????
?????????????cereal???л???????????????????????д??????л??????????????????????????????cereal??????????????????
???????????????cereal?????????????????????????
????????Boost??????????cereal????????????????????ù?Boost?????л????????cereal?????????????????
????????????Boost??????cereal????????????????????http://uscilab.github.io/cereal/transition_from_boost.html
???????????
?????e???????????????????????????
????std::ofstream os("my.xml");
????cereal::XMLOutputArchive archive(os);
????int age = 26;
????std::string name = "lizheng";
????archive(CEREAL_NVP(age)?? cereal::make_nvp("Name"?? name));
????????????????????int?????string?????xml???л???????????£?
????<?xml version="1.0" encoding="utf-8"?>
????<cereal>
????<age>26</age>
????<Name>lizheng</Name>
????</cereal>
???????????????е?cereal::XMLOutputArchive????????????JSON???????????л?????????????л??JSON??????????£??????????棩??
????{
????"age": 26??
????"Name": "lizheng"
????}