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

Function dispatch

include/process/dispatch.hpp:174–186  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

172
173template <typename T>
174void dispatch(const PID<T>& pid, void (T::*method)())
175{
176 std::unique_ptr<lambda::CallableOnce<void(ProcessBase*)>> f(
177 new lambda::CallableOnce<void(ProcessBase*)>(
178 [=](ProcessBase* process) {
179 assert(process != nullptr);
180 T* t = dynamic_cast<T*>(process);
181 assert(t != nullptr);
182 (t->*method)();
183 }));
184
185 internal::dispatch(pid, std::move(f), &typeid(method));
186}
187
188template <typename T>
189void dispatch(const Process<T>& process, void (T::*method)())

Callers 15

delayFunction · 0.70
startMethod · 0.70
executeMethod · 0.70
callMethod · 0.70
executeMethod · 0.70
operator()Method · 0.70
operator()Method · 0.70
operator()Method · 0.70
deferFunction · 0.70
addMethod · 0.70
operator()Method · 0.70

Calls 4

selfMethod · 0.80
futureMethod · 0.80
associateMethod · 0.80
setMethod · 0.45

Tested by

no test coverage detected