MCPcopy Create free account
hub / github.com/3rdparty/libprocess / handlerN

Method handlerN

include/process/protobuf.hpp:303–320  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

301 template <typename M,
302 typename ...P, typename ...PC>
303 static void handlerN(
304 T* t,
305 void (T::*method)(const process::UPID&, PC...),
306 const process::UPID& sender,
307 const std::string& data,
308 MessageProperty<M, P>... p)
309 {
310 google::protobuf::Arena arena;
311 M* m = CHECK_NOTNULL(google::protobuf::Arena::CreateMessage<M>(&arena));
312 m->ParseFromString(data);
313
314 if (m->IsInitialized()) {
315 (t->*method)(sender, google::protobuf::convert((m->*p)())...);
316 } else {
317 LOG(WARNING) << "Initialization errors: "
318 << m->InitializationErrorString();
319 }
320 }
321
322 // Handlers that ignore the sender.
323 template <typename M>

Callers

nothing calls this directly

Calls 1

convertFunction · 0.70

Tested by

no test coverage detected