diff --git a/include/KeyValuePair.hpp b/include/KeyValuePair.hpp new file mode 100644 index 0000000..f0cfa5a --- /dev/null +++ b/include/KeyValuePair.hpp @@ -0,0 +1,24 @@ +#ifndef KeyValuePairH +#define KeyValuePairH + +template +struct KeyValuePair +{ +public: + KeyValuePair() {} + KeyValuePair(K key, V value) + { + this->Key = new K(key); + this->Value = new V(value); + } + + K *Key = nullptr; + V *Value = nullptr; + + K GetKey() { return (K)*Key; } + V GetValue() { return (V)*Value; } + + void SetKey(K Key) { this->Key = &Key; } + void SetValue(V Value) { this->Value = &Value; } +}; +#endif \ No newline at end of file