diff options
author | Claudius "keldu" Holeksa <mail@keldu.de> | 2023-12-04 12:18:14 +0100 |
---|---|---|
committer | Claudius "keldu" Holeksa <mail@keldu.de> | 2023-12-04 12:18:14 +0100 |
commit | a14896f9ed209dd3f9597722e5a5697bd7dbf531 (patch) | |
tree | 089ca5cbbd206d1921f8f6b53292f5bc1902ca5c /c++/core/id.h | |
parent | 84ecdcbca9e55b1f57fbb832e12ff4fdbb86e7c9 (diff) |
meta: Renamed folder containing source
Diffstat (limited to 'c++/core/id.h')
-rw-r--r-- | c++/core/id.h | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/c++/core/id.h b/c++/core/id.h deleted file mode 100644 index d836648..0000000 --- a/c++/core/id.h +++ /dev/null @@ -1,54 +0,0 @@ -#pragma once - -namespace saw { -/** - * ID class which is tied to it's representing class - */ -template<typename T> -class id { -private: - /** - * Alias for the value type representing the ID - */ - using type = uint64_t; - - /** - * The low level value - */ - type value_; -public: - /** - * Basic constructor for the id class - */ - id(type val): - value_{val} - {} - - SAW_DEFAULT_COPY(id); - SAW_DEFAULT_MOVE(id); - - /** - * Equal operator for the id. - * Returns true if equal, false otherwise. - */ - bool operator==(const id<T>& rhs) const { - return value_ == rhs.value_; - } - - /** - * Unequal operator for the id. - * Returns false if equal, true otherwise. - */ - bool operator!=(const id<T>& rhs) const { - return !(*this == rhs); - } - - /** - * Returns a const ref of the underlying base type. - * Mostly used for internal purposes. - */ - const type& get_value() const { - return value_; - } -}; -} |