cache: Add dummy NoCache class

This commit is contained in:
Albert S. 2023-07-29 09:45:51 +02:00
parent 1095d38b02
commit ec3cbe3f76
1 changed files with 30 additions and 0 deletions

30
cache/nocache.h vendored Normal file
View File

@ -0,0 +1,30 @@
#include "icache.h"
class NoCache : public ICache
{
public:
NoCache(std::string p)
{
}
virtual std::optional<std::string> get(std::string_view key) const
{
return {};
}
virtual void put(std::string_view key, std::string val)
{
return;
}
virtual void remove(std::string_view key)
{
return;
}
virtual void removePrefix(std::string_view prefix)
{
return;
}
virtual void clear()
{
return;
}
};