Text-Adventure/Serializable.cpp
2023-11-16 00:44:12 +08:00

16 lines
258 B
C++

//
// Created by tqcq on 2023/11/14.
//
#include "Serializable.h"
void Serializable::serialize(std::ostream &os) const {
os << ToString();
}
void Serializable::deserialize(std::istream &is) {
std::string str;
is >> str;
FromString(str);
}