MCPcopy Create free account
hub / github.com/Prograda/Skybolt / create

Method create

src/Skybolt/SkyboltEngine/EngineRootFactory.cpp:30–44  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28}
29
30std::unique_ptr<EngineRoot> EngineRootFactory::create(const boost::program_options::variables_map& params)
31{
32 std::vector<PluginFactory> enginePluginFactories = loadPluginFactories<Plugin, PluginConfig>(getAllPluginFilepathsInDirectories(getDefaultPluginDirs()));
33
34 try
35 {
36 nlohmann::json settings = readEngineSettings(params);
37 return create(enginePluginFactories, settings);
38 }
39 catch (const std::exception& e)
40 {
41 // Catch and re-throw a copy of the exception to avoid issues with exceptions crossing shared library boundaries
42 throw std::exception(e);
43 }
44}
45
46std::unique_ptr<EngineRoot> EngineRootFactory::create(const std::vector<PluginFactory>& pluginFactories, const json& settings)
47{

Callers 1

createEntityFromJsonMethod · 0.45

Calls 3

readEngineSettingsFunction · 0.85
loadPluginsMethod · 0.80

Tested by

no test coverage detected