From f12e2936fda51eb59016dd316ff9c73fba621fa2 Mon Sep 17 00:00:00 2001 From: thecharlesblake Date: Fri, 12 Jan 2018 16:31:16 +0000 Subject: Add basic global_cache interface --- src/main/game/global_cache.h | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 src/main/game/global_cache.h (limited to 'src/main/game/global_cache.h') diff --git a/src/main/game/global_cache.h b/src/main/game/global_cache.h new file mode 100644 index 0000000..b35acc6 --- /dev/null +++ b/src/main/game/global_cache.h @@ -0,0 +1,29 @@ +// +// Created by thecharlesblake on 1/10/18. +// + +#ifndef SOLVITAIRE_GLOBAL_CACHE_H +#define SOLVITAIRE_GLOBAL_CACHE_H + +#include +#include + +#include "../game/game_state.h" +#include "../game/sol_rules.h" + +class global_cache { +public: + explicit global_cache(const sol_rules&); + + bool insert(const std::vector&); + bool contains(const std::vector&); + +private: + std::unordered_set< + std::vector, + boost::hash> + > u_set; +}; + + +#endif //SOLVITAIRE_GLOBAL_CACHE_H -- cgit v1.2.1