| 1592 | } |
| 1593 | |
| 1594 | bool AFCKernelModule::DBDataToContainer( |
| 1595 | std::shared_ptr<AFIEntity> pEntity, const std::string& name, const AFMsg::pb_db_container& pb_data) |
| 1596 | { |
| 1597 | auto pContainer = pEntity->FindContainer(name); |
| 1598 | if (nullptr == pContainer) |
| 1599 | { |
| 1600 | return false; |
| 1601 | } |
| 1602 | |
| 1603 | auto pCContainer = std::dynamic_pointer_cast<AFCContainer>(pContainer); |
| 1604 | if (nullptr == pCContainer) |
| 1605 | { |
| 1606 | return false; |
| 1607 | } |
| 1608 | |
| 1609 | for (auto& iter : pb_data.datas_value()) |
| 1610 | { |
| 1611 | auto pContainerEntity = CreateEntity(iter.second); |
| 1612 | if (nullptr == pContainerEntity) |
| 1613 | { |
| 1614 | continue; |
| 1615 | } |
| 1616 | |
| 1617 | pCContainer->InitEntityList(iter.first, pContainerEntity); |
| 1618 | } |
| 1619 | |
| 1620 | return true; |
| 1621 | } |
| 1622 | |
| 1623 | int AFCKernelModule::OnContainerCallBack(const AFGUID& self, const uint32_t index, const ArkContainerOpType op_type, |
| 1624 | const uint32_t src_index, const uint32_t dest_index) |
nothing calls this directly
no test coverage detected