MCPcopy Create free account
hub / github.com/OpenArkStudio/ARK / RegMsgCallback

Method RegMsgCallback

src/plugin/net/src/AFCNetServerService.cpp:82–93  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

80}
81
82bool AFCNetServerService::RegMsgCallback(const int msg_id, NET_MSG_FUNCTOR&& cb)
83{
84 if (net_msg_callbacks_.find(msg_id) != net_msg_callbacks_.end())
85 {
86 return false;
87 }
88 else
89 {
90 net_msg_callbacks_.insert(std::make_pair(msg_id, std::forward<NET_MSG_FUNCTOR>(cb)));
91 return true;
92 }
93}
94
95bool AFCNetServerService::RegForwardMsgCallback(NET_MSG_FUNCTOR&& cb)
96{

Callers

nothing calls this directly

Calls 3

findMethod · 0.45
endMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected