Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(989)

Unified Diff: content/renderer/dom_storage/local_storage_cached_areas.h

Issue 1814003002: Implement the renderer side of the mojo based local storage implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/renderer/dom_storage/local_storage_cached_areas.h
diff --git a/content/renderer/dom_storage/local_storage_cached_areas.h b/content/renderer/dom_storage/local_storage_cached_areas.h
index fba1daa4eed32c195a97dd05ca634c6773dc3c08..e4cb949031deb1cbfc0c839194ffd67506bf898a 100644
--- a/content/renderer/dom_storage/local_storage_cached_areas.h
+++ b/content/renderer/dom_storage/local_storage_cached_areas.h
@@ -15,9 +15,9 @@ namespace content {
class LocalStorageCachedArea;
class StoragePartitionService;
-// Owns all the LocalStorageCachedArea objects in a renderer. This is needed
-// because we can have n LocalStorageArea objects for the same origin but we
-// want just one LocalStorageCachedArea to service them (no point in having
+// Keeps a map of all the LocalStorageCachedArea objects in a renderer. This is
+// needed because we can have n LocalStorageArea objects for the same origin but
+// we want just one LocalStorageCachedArea to service them (no point in having
// multiple caches of the same data in the same process).
class LocalStorageCachedAreas {
public:
@@ -25,11 +25,12 @@ class LocalStorageCachedAreas {
StoragePartitionService* storage_partition_service);
~LocalStorageCachedAreas();
- scoped_refptr<LocalStorageCachedArea> GetLocalStorageCachedArea(
- const url::Origin& origin);
+ // Returns, creating if necessary, a cached storage area for the given origin.
+ scoped_refptr<LocalStorageCachedArea>
+ GetCachedArea(const url::Origin& origin);
// Called by LocalStorageCachedArea on destruction.
- void LocalStorageCacheAreaClosed(LocalStorageCachedArea* cached_area);
+ void CacheAreaClosed(LocalStorageCachedArea* cached_area);
private:
StoragePartitionService* const storage_partition_service_;
« no previous file with comments | « content/renderer/dom_storage/local_storage_cached_area.cc ('k') | content/renderer/dom_storage/local_storage_cached_areas.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698