diff options
author | Roman Smrž <roman.smrz@seznam.cz> | 2023-04-08 18:35:46 +0200 |
---|---|---|
committer | Roman Smrž <roman.smrz@seznam.cz> | 2023-04-08 18:35:46 +0200 |
commit | a9a5308cf03fcd25492317b844a59019eacfac13 (patch) | |
tree | f7f6d8e1d42cc8280bff98511d55a234371903fa /include/erebos | |
parent | 182dd4271c96305c69e0a950a4cdada38d39eac8 (diff) |
Empty record item type
Diffstat (limited to 'include/erebos')
-rw-r--r-- | include/erebos/storage.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/erebos/storage.h b/include/erebos/storage.h index c506dfd..ed537eb 100644 --- a/include/erebos/storage.h +++ b/include/erebos/storage.h @@ -230,8 +230,11 @@ public: std::string value; }; + struct Empty {}; + typedef std::variant< std::monostate, + Empty, int, std::string, std::vector<uint8_t>, @@ -253,6 +256,7 @@ public: operator bool() const; + std::optional<Empty> asEmpty() const; std::optional<int> asInteger() const; std::optional<std::string> asText() const; std::optional<std::vector<uint8_t>> asBinary() const; |