mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2026-01-23 00:31:48 +00:00
chore: use CommonTechset instead of TechsetDefinition
This commit is contained in:
21
src/ObjLoading/Techset/CommonTechsetCache.h
Normal file
21
src/ObjLoading/Techset/CommonTechsetCache.h
Normal file
@@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
|
||||
#include "Asset/IZoneAssetCreationState.h"
|
||||
#include "Techset/CommonTechset.h"
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include <unordered_map>
|
||||
|
||||
namespace techset
|
||||
{
|
||||
class CommonTechsetCache final : public IZoneAssetCreationState
|
||||
{
|
||||
public:
|
||||
[[nodiscard]] CommonTechset* GetCachedTechsetDefinition(const std::string& techsetName) const;
|
||||
void AddCommonTechsetToCache(std::string name, std::unique_ptr<CommonTechset> definition);
|
||||
|
||||
private:
|
||||
std::unordered_map<std::string, std::unique_ptr<CommonTechset>> m_cache;
|
||||
};
|
||||
} // namespace techset
|
||||
Reference in New Issue
Block a user