aboutsummaryrefslogtreecommitdiff
path: root/src/openvic/map/Building.hpp
diff options
context:
space:
mode:
author Hop311 <hop3114@gmail.com>2023-08-12 15:10:40 +0200
committer Hop311 <hop3114@gmail.com>2023-08-12 15:10:40 +0200
commitafc16e76ba699b24ba1ef1cb1b658ef421c84430 (patch)
treee4bf26ecfef160e7df7670e73af7f154f1550308 /src/openvic/map/Building.hpp
parent538e7dc4ec44c4d09a6a654f10229e6392653a50 (diff)
std::string const& --> const std::string_view
Diffstat (limited to 'src/openvic/map/Building.hpp')
-rw-r--r--src/openvic/map/Building.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/openvic/map/Building.hpp b/src/openvic/map/Building.hpp
index c4f8950..c00932b 100644
--- a/src/openvic/map/Building.hpp
+++ b/src/openvic/map/Building.hpp
@@ -60,7 +60,7 @@ namespace OpenVic {
const Building::level_t max_level;
const Timespan build_time;
- BuildingType(std::string const& new_identifier, Building::level_t new_max_level, Timespan new_build_time);
+ BuildingType(const std::string_view new_identifier, Building::level_t new_max_level, Timespan new_build_time);
public:
BuildingType(BuildingType&&) = default;
@@ -78,9 +78,9 @@ namespace OpenVic {
public:
BuildingManager();
- return_t add_building_type(std::string const& identifier, Building::level_t max_level, Timespan build_time);
+ return_t add_building_type(const std::string_view identifier, Building::level_t max_level, Timespan build_time);
void lock_building_types();
- BuildingType const* get_building_type_by_identifier(std::string const& identifier) const;
+ BuildingType const* get_building_type_by_identifier(const std::string_view identifier) const;
return_t generate_province_buildings(Province& province) const;
};
}