#ifndef MBGL_STORAGE_DEFAULT_SQLITE_CACHE #define MBGL_STORAGE_DEFAULT_SQLITE_CACHE #include #include namespace mbgl { namespace util { template class Thread; } class SQLiteCache : public FileCache { public: SQLiteCache(const std::string &path = ":memory:"); ~SQLiteCache() override; // FileCache API std::unique_ptr get(const Resource &resource, Callback callback) override; void put(const Resource &resource, std::shared_ptr response, Hint hint) override; class Impl; private: const std::unique_ptr> thread; }; class SharedSQLiteCache : util::noncopyable { public: static std::shared_ptr get(const std::string &path = ":memory:"); private: SharedSQLiteCache() {} static std::weak_ptr masterPtr; }; } #endif