MCPcopy Create free account
hub / github.com/Tencent/rapidjson / Serialize

Method Serialize

example/serialize/serialize.cpp:51–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

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
67private:
68 std::string school_;

Callers

nothing calls this directly

Calls 4

StartObjectMethod · 0.45
StringMethod · 0.45
DoubleMethod · 0.45
EndObjectMethod · 0.45

Tested by

no test coverage detected