MCPcopy Create free account
hub / github.com/IppClub/Dora-SSR / sendLog

Method sendLog

Source/Http/HttpServer.cpp:258–268  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

256 }
257
258 void sendLog(const std::string& log) {
259 rapidjson::StringBuffer buf;
260 rapidjson::Writer<rapidjson::StringBuffer> writer(buf);
261 writer.StartObject();
262 writer.Key("name");
263 writer.String("Log");
264 writer.Key("text");
265 writer.String(log.c_str(), log.size());
266 writer.EndObject();
267 Event::send("AppWS"sv, makeAppWSMessage("Send"_slice, std::string{buf.GetString(), buf.GetLength()}));
268 }
269
270 bool start(int port) {
271 try {

Callers

nothing calls this directly

Calls 8

makeAppWSMessageFunction · 0.70
StringMethod · 0.65
StartObjectMethod · 0.45
KeyMethod · 0.45
c_strMethod · 0.45
sizeMethod · 0.45
EndObjectMethod · 0.45
GetLengthMethod · 0.45

Tested by

no test coverage detected