From 6fd50506d2e50d2faf2478a2883a2ef1b4840a78 Mon Sep 17 00:00:00 2001 From: Douglas Rumbaugh Date: Wed, 17 May 2023 16:00:20 -0400 Subject: Started implementing shard interface (not finished yet) --- include/framework/ShardInterface.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 include/framework/ShardInterface.h (limited to 'include/framework/ShardInterface.h') diff --git a/include/framework/ShardInterface.h b/include/framework/ShardInterface.h new file mode 100644 index 0000000..5d07a99 --- /dev/null +++ b/include/framework/ShardInterface.h @@ -0,0 +1,27 @@ +/* + * include/shard/ShardInterface.h + * + * Copyright (C) 2023 Douglas Rumbaugh + * + * All rights reserved. Published under the Modified BSD License. + * + */ +#pragma once + +#include + +#include "util/types.h" + +template +concept ShardInterface = requires(S s, void *p) { + //s.point_lookup(); + //s.tombstone_lookup(); + //s.delete_record(); + + {s.get_query_state(p)} -> std::convertible_to; + {s.delete_query_state(p)}; + + {s.get_record_count()} -> std::convertible_to; + {s.get_tombstone_count()} -> std::convertible_to; + {s.get_memory_usage()} -> std::convertible_to; +}; -- cgit v1.2.3