| 22 | } |
| 23 | |
| 24 | SImporter* SImporterRegistryImpl::LoadImporter(const SAssetRecord* record, simdjson::ondemand::value&& object, skr_guid_t* pGuid) |
| 25 | { |
| 26 | skr_guid_t type; |
| 27 | skr::json::Read(object["importerType"].value_unsafe(), type); |
| 28 | if (pGuid) *pGuid = type; |
| 29 | auto iter = loaders.find(type); |
| 30 | if (iter != loaders.end()) |
| 31 | return iter->second.Load(record, std::move(object)); |
| 32 | return nullptr; |
| 33 | } |
| 34 | uint32_t SImporterRegistryImpl::GetImporterVersion(skr_guid_t type) |
| 35 | { |
| 36 | auto iter = loaders.find(type); |