#include "SampleRepository.h" #include #include #include #include #include #include namespace kurator { namespace universe { static const std::unordered_map ships { {"Anvil", {"Anvil", 600.0, 218.0}}, {"Eclipse", {"Eclipse", 600.0, 263.0}}, {"Warbringer", {"Warbringer", 600.0, 336.0}}, }; static const std::unordered_map turrets { {"ChargeLaser", {"ChargeLaser", 85.0, 4.5, 7000.0, 0.05, 0.2}}, }; ShipType SampleRepository::ship_type(const std::string& id) const try { return ships.at(id); } catch (const std::out_of_range&) { throw NotFound(id); } TurretType SampleRepository::turret_type(const std::string& id) const try { return turrets.at(id); } catch (const std::out_of_range&) { throw NotFound(id); } } // namespace universe } // namespace kurator