20 #ifdef GTSAM_ENABLE_BOOST_SERIALIZATION
25 #include <boost/serialization/array.hpp>
26 #include <boost/serialization/nvp.hpp>
27 #include <boost/serialization/split_free.hpp>
30 namespace serialization {
33 template <
class Archive>
35 const size_t size =
v.size();
36 ar << BOOST_SERIALIZATION_NVP(
size);
37 ar << make_nvp(
"data", make_array(
v.data(),
v.size()));
40 template <
class Archive>
43 ar >> BOOST_SERIALIZATION_NVP(
size);
45 ar >> make_nvp(
"data", make_array(
v.data(),
v.size()));
49 template <
class Archive,
int D>
52 ar << make_nvp(
"data", make_array(
v.data(),
v.RowsAtCompileTime));
55 template <
class Archive,
int D>
58 ar >> make_nvp(
"data", make_array(
v.data(),
v.RowsAtCompileTime));
67 BOOST_SERIALIZATION_SPLIT_FREE(gtsam::Vector6)