aboutsummaryrefslogtreecommitdiff
path: root/extension/src/openvic2/Types.hpp
diff options
context:
space:
mode:
author Spartan322 <Megacake1234@gmail.com>2023-04-24 05:36:42 +0200
committer Spartan322 <Megacake1234@gmail.com>2023-05-02 00:50:24 +0200
commit112de0ac9c7ce26bd75d06e4cd3bc91adee716e3 (patch)
tree8c2376ce06c164e10fe815723e5601f2a7bebf02 /extension/src/openvic2/Types.hpp
parentb1e985e0774598b3add22069be50f891e981fd79 (diff)
Support features up to clang-format 14
Add .editorconfig Update C++ files within `extension/src` to follow .clang-format
Diffstat (limited to 'extension/src/openvic2/Types.hpp')
-rw-r--r--extension/src/openvic2/Types.hpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/extension/src/openvic2/Types.hpp b/extension/src/openvic2/Types.hpp
index e4a0e2d..a01bae4 100644
--- a/extension/src/openvic2/Types.hpp
+++ b/extension/src/openvic2/Types.hpp
@@ -1,9 +1,9 @@
#pragma once
-#include <vector>
-#include <cstdint>
#include <algorithm>
+#include <cstdint>
#include <map>
+#include <vector>
#include "Logger.hpp"
@@ -37,8 +37,10 @@ namespace OpenVic2 {
*/
class HasIdentifier {
const std::string identifier;
+
protected:
HasIdentifier(std::string const& new_identifier);
+
public:
HasIdentifier(HasIdentifier const&) = delete;
HasIdentifier(HasIdentifier&&) = default;
@@ -53,8 +55,10 @@ namespace OpenVic2 {
*/
class HasColour {
const colour_t colour;
+
protected:
HasColour(colour_t const new_colour);
+
public:
HasColour(HasColour const&) = delete;
HasColour(HasColour&&) = default;
@@ -80,6 +84,7 @@ namespace OpenVic2 {
std::vector<T> items;
bool locked = false;
identifier_index_map_t identifier_index_map;
+
public:
IdentifierRegistry(std::string const& new_name) : name(new_name) {}
return_t add_item(T&& item) {