MCPcopy Create free account
hub / github.com/1a1a11a/libCacheSim / add_cache

Method add_cache

example/cacheCluster/include/cacheServer.hpp:66–71  ·  view source on GitHub ↗

* @brief add a cache to this server * return the index of the cache in this server * * @param cache * @return size_t */

Source from the content-addressed store, hash-verified

64 * @return size_t
65 */
66 inline size_t add_cache(Cache&& cache) {
67 // this->_cache_vec.emplace_back(cache_size, cache_alg, hashpower);
68
69 this->_cache_vec.push_back(std::move(cache));
70 return this->_cache_vec.size() - 1;
71 }
72
73 inline bool get(request_t* req) {
74 if (!_available) return false;

Callers 1

simulateFunction · 0.80

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected