16 void operator()(std::istream& is, T& t) {
17 is.read(
reinterpret_cast<char*
>(&t),
sizeof(t));
23 void operator()(std::ostream& os, T& t) {
24 os.write(
reinterpret_cast<char*
>(&t),
sizeof(t));
29 void load(
const std::string& filename, T& t) {
30 std::ifstream ifs(filename, std::ios::binary);
32 throw std::runtime_error(
"Cannot open file: " + filename);
39 void save(
const std::string& filename, T& t) {
40 std::ofstream ofs(filename, std::ios::binary);
42 throw std::runtime_error(
"Cannot open file: " + filename);
本系统的主命名空间,包含了common, examples, fmm, geometry, numeric, point_cloud等子命名空间