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

Method OnContainerCallBack

src/plugin/kernel/src/AFClassCallBackManager.cpp:194–227  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

192}
193
194bool AFClassCallBackManager::OnContainerCallBack(const AFGUID& self, const uint32_t index, const ArkMaskType mask,
195 const ArkContainerOpType op_type, uint32_t src_index, uint32_t dest_index,
196 std::shared_ptr<AFIEntity> src_entity /* = nullptr*/)
197{
198 // sync call back
199 if (mask.test((size_t)ArkDataMask::PF_REAL_TIME))
200 {
201 for (auto& iter : container_sync_call_backs_list_)
202 {
203 auto mask_value = iter.first;
204 if (!mask.test((size_t)mask_value))
205 {
206 continue;
207 }
208
209 iter.second(self, index, mask_value, op_type, src_index, dest_index);
210 }
211 }
212 else
213 {
214 UpdateDelayContainerList(self, index, mask, op_type, src_index, dest_index, src_entity);
215 }
216
217 auto iter_call_backs = container_call_backs_list_.find(index);
218 if (iter_call_backs != container_call_backs_list_.end())
219 {
220 for (auto& iter : iter_call_backs->second)
221 {
222 iter.second(self, index, op_type, src_index, dest_index);
223 }
224 }
225
226 return true;
227}
228
229bool AFClassCallBackManager::OnLeaveSceneEvent(const AFGUID& self, const int map_id, const int map_inst_id)
230{

Callers

nothing calls this directly

Calls 2

findMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected