diff options
author | Hop311 <hop3114@gmail.com> | 2023-08-12 15:10:40 +0200 |
---|---|---|
committer | Hop311 <hop3114@gmail.com> | 2023-08-12 15:10:40 +0200 |
commit | afc16e76ba699b24ba1ef1cb1b658ef421c84430 (patch) | |
tree | e4bf26ecfef160e7df7670e73af7f154f1550308 /src/openvic/map/Province.hpp | |
parent | 538e7dc4ec44c4d09a6a654f10229e6392653a50 (diff) |
std::string const& --> const std::string_view
Diffstat (limited to 'src/openvic/map/Province.hpp')
-rw-r--r-- | src/openvic/map/Province.hpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/openvic/map/Province.hpp b/src/openvic/map/Province.hpp index 3ca5d93..20c5870 100644 --- a/src/openvic/map/Province.hpp +++ b/src/openvic/map/Province.hpp @@ -29,7 +29,7 @@ namespace OpenVic { Pop::pop_size_t total_population; distribution_t pop_types, cultures; - Province(index_t new_index, std::string const& new_identifier, colour_t new_colour); + Province(const std::string_view new_identifier, colour_t new_colour, index_t new_index); public: Province(Province&&) = default; @@ -41,9 +41,9 @@ namespace OpenVic { return_t add_building(Building&& building); void lock_buildings(); void reset_buildings(); - Building const* get_building_by_identifier(std::string const& identifier) const; + Building const* get_building_by_identifier(const std::string_view identifier) const; std::vector<Building> const& get_buildings() const; - return_t expand_building(std::string const& building_type_identifier); + return_t expand_building(const std::string_view building_type_identifier); Good const* get_rgo() const; std::string to_string() const; |