14#include "../../Source/third_party/nlohmann/json.hpp"
44 bool SaveToFile(
const std::string& filepath)
const;
80 const std::string& name,
81 const std::string& description,
82 const std::string& category,
83 const std::string& author =
"User"
ComponentTypeID GetComponentTypeID_Static()
TemplateManager - Manages blueprint templates Singleton manager for template catalog and operations.
bool SaveTemplate(const BlueprintTemplate &tpl)
std::string m_TemplatesPath
void Initialize(const std::string &templatesPath="Blueprints/Templates")
std::string GenerateUUID() const
bool DeleteTemplate(const std::string &templateId)
std::vector< BlueprintTemplate > m_Templates
bool EnsureDirectoryExists(const std::string &path)
std::vector< BlueprintTemplate > GetTemplatesByCategory(const std::string &category) const
bool ApplyTemplateToBlueprint(const std::string &templateId, json &targetBlueprint)
bool IsInitialized() const
static TemplateManager & Instance()
const BlueprintTemplate * FindTemplate(const std::string &id) const
void ScanTemplateDirectory()
std::string GetLastError() const
bool LoadTemplates(const std::string &templatesPath)
const std::string & GetTemplatesPath() const
static TemplateManager & Get()
const std::vector< BlueprintTemplate > & GetAllTemplates() const
TemplateManager & operator=(const TemplateManager &)=delete
BlueprintTemplate CreateTemplateFromBlueprint(const json &blueprint, const std::string &name, const std::string &description, const std::string &category, const std::string &author="User")
std::vector< std::string > GetAllCategories() const
TemplateManager(const TemplateManager &)=delete
BlueprintTemplate - Template metadata and data Stores a complete blueprint that can be reused as a te...
std::string thumbnailPath
static BlueprintTemplate LoadFromFile(const std::string &filepath)
static BlueprintTemplate FromJson(const json &j)
bool SaveToFile(const std::string &filepath) const