bool process_cache::fetch(string const &key,archive &a,set<string> &tags) { rwlock_rdlock lock(access_lock); shr_string *r=get(key,&tags); if(!r) return false; a.set(r->c_str(),r->size()); return true; }
bool thread_cache::fetch(string const &key,archive &a,set<string> &tags) { rwlock_rdlock lock(access_lock); string *r=get(key,&tags); if(!r) return false; a.set(*r); return true; }