| 43 | } |
| 44 | |
| 45 | class Education { |
| 46 | public: |
| 47 | Education(const std::string& school, double GPA) : school_(school), GPA_(GPA) {} |
| 48 | Education(const Education& rhs) : school_(rhs.school_), GPA_(rhs.GPA_) {} |
| 49 | |
| 50 | template <typename Writer> |
| 51 | void Serialize(Writer& writer) const { |
| 52 | writer.StartObject(); |
| 53 | |
| 54 | writer.String("school"); |
| 55 | #if RAPIDJSON_HAS_STDSTRING |
| 56 | writer.String(school_); |
| 57 | #else |
| 58 | writer.String(school_.c_str(), static_cast<SizeType>(school_.length())); |
| 59 | #endif |
| 60 | |
| 61 | writer.String("GPA"); |
| 62 | writer.Double(GPA_); |
| 63 | |
| 64 | writer.EndObject(); |
| 65 | } |
| 66 | |
| 67 | private: |
| 68 | std::string school_; |
| 69 | double GPA_; |
| 70 | }; |
| 71 | |
| 72 | class Dependent : public Person { |
| 73 | public: |
nothing calls this directly
no outgoing calls
no test coverage detected