hdk-grid 0.0.1
Header-only foundational library for the Hollow Development Kit.
Loading...
Searching...
No Matches
PrimitiveWrapper.hpp
Go to the documentation of this file.
1#pragma once
4//
5namespace hdk::grid {
6 template <typename T>
8 private:
9 T primitive_value;
10 public:
11 PrimitiveWrapper() = delete;
12 PrimitiveWrapper(T value) : primitive_value(value) {}
13 operator T() const { return primitive_value; }
15 primitive_value = newValue;
16 return *this;
17 }
18 };
19}
PrimitiveWrapper & operator=(T newValue)
Assign a new primitive value.
PrimitiveWrapper(T value)
Construct with a primitive value.