Home | History | Annotate | Download | only in base

Lines Matching refs:path_data

149 // Tries to find |key| in the cache. |path_data| should be locked by the caller!
150 bool LockedGetFromCache(int key, const PathData* path_data, FilePath* result) {
151 if (path_data->cache_disabled)
154 PathMap::const_iterator it = path_data->cache.find(key);
155 if (it != path_data->cache.end()) {
162 // Tries to find |key| in the overrides map. |path_data| should be locked by the
164 bool LockedGetFromOverrides(int key, PathData* path_data, FilePath* result) {
166 PathMap::const_iterator it = path_data->overrides.find(key);
167 if (it != path_data->overrides.end()) {
168 if (!path_data->cache_disabled)
169 path_data->cache[key] = it->second;
183 PathData* path_data = GetPathData();
184 DCHECK(path_data);
194 base::AutoLock scoped_lock(path_data->lock);
195 if (LockedGetFromCache(key, path_data, result))
198 if (LockedGetFromOverrides(key, path_data, result))
202 provider = path_data->providers;
227 base::AutoLock scoped_lock(path_data->lock);
228 if (!path_data->cache_disabled)
229 path_data->cache[key] = path;
244 PathData* path_data = GetPathData();
245 DCHECK(path_data);
266 base::AutoLock scoped_lock(path_data->lock);
270 path_data->cache.clear();
272 path_data->overrides[key] = file_path;
279 PathData* path_data = GetPathData();
280 DCHECK(path_data);
282 base::AutoLock scoped_lock(path_data->lock);
284 if (path_data->overrides.find(key) == path_data->overrides.end())
289 path_data->cache.clear();
291 path_data->overrides.erase(key);
299 PathData* path_data = GetPathData();
300 DCHECK(path_data);
313 base::AutoLock scoped_lock(path_data->lock);
316 Provider *iter = path_data->providers;
324 p->next = path_data->providers;
325 path_data->providers = p;
330 PathData* path_data = GetPathData();
331 DCHECK(path_data);
333 base::AutoLock scoped_lock(path_data->lock);
334 path_data->cache.clear();
335 path_data->cache_disabled = true;