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

Method _handlerN

include/process/protobuf.hpp:371–388  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

369 template <typename M,
370 typename ...P, typename ...PC>
371 static void _handlerN(
372 T* t,
373 void (T::*method)(PC...),
374 const process::UPID&,
375 const std::string& data,
376 MessageProperty<M, P>... p)
377 {
378 google::protobuf::Arena arena;
379 M* m = CHECK_NOTNULL(google::protobuf::Arena::CreateMessage<M>(&arena));
380 m->ParseFromString(data);
381
382 if (m->IsInitialized()) {
383 (t->*method)(google::protobuf::convert((m->*p)())...);
384 } else {
385 LOG(WARNING) << "Initialization errors: "
386 << m->InitializationErrorString();
387 }
388 }
389
390 typedef lambda::function<
391 void(const process::UPID&, const std::string&)> handler;

Callers

nothing calls this directly

Calls 1

convertFunction · 0.70

Tested by

no test coverage detected