diff options
| author | Estevan Castilho <tevo@riajuu.net> | 2026-07-02 00:31:57 +0000 |
|---|---|---|
| committer | Estevan Castilho <tevo@riajuu.net> | 2026-07-02 00:31:57 +0000 |
| commit | ab70e5461b98ddf2b56268c53c171cab89157027 (patch) | |
| tree | 3e57218edacc8e1366e0d1a86bdb922af7e51dca /include/InMemoryBackend.h | |
| parent | a4f6637601548a7158869ad155f29db50b151823 (diff) | |
| download | RNT-ab70e5461b98ddf2b56268c53c171cab89157027.tar.gz RNT-ab70e5461b98ddf2b56268c53c171cab89157027.zip | |
Nuke the old code
Diffstat (limited to '')
| -rw-r--r-- | include/InMemoryBackend.h | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/include/InMemoryBackend.h b/include/InMemoryBackend.h deleted file mode 100644 index b66d355..0000000 --- a/include/InMemoryBackend.h +++ /dev/null @@ -1,31 +0,0 @@ -#pragma once - -#include "Api.h" -#include "IStorageBackend.h" - -#include <cstdint> -#include <optional> -#include <string> -#include <unordered_map> -#include <vector> - -/** - * @file InMemoryBackend.h - * @brief In-process KV storage backend backed by an unordered_map. - * - * Intended for unit tests where SQLite is not appropriate. Data does not - * survive process exit and is not thread-safe. - * - * Relation membership is tracked by the Merkle class, not this backend. - */ - -namespace nt { - class InMemoryBackend : public IStorageBackend { - public: - std::string Put(std::vector<uint8_t> value) override; - std::optional<std::vector<uint8_t>> Get(const std::string& hash) override; - - private: - std::unordered_map<std::string, std::vector<uint8_t>> kv_; - }; -} // namespace nt |
