| Index: content/browser/service_worker/service_worker_cache_storage.h
|
| diff --git a/content/browser/service_worker/service_worker_cache_storage.h b/content/browser/service_worker/service_worker_cache_storage.h
|
| index ca2adc3c060bb99ead2daf729850a993dc58e25e..666ae6287a3da85c13ffcfc0293600deb4029dbf 100644
|
| --- a/content/browser/service_worker/service_worker_cache_storage.h
|
| +++ b/content/browser/service_worker/service_worker_cache_storage.h
|
| @@ -99,10 +99,15 @@ class CONTENT_EXPORT ServiceWorkerCacheStorage {
|
| typedef std::map<CacheID, CacheContext*> CacheMap;
|
| typedef std::map<std::string, CacheID> NameMap;
|
|
|
| + // Scans the filesystem for stored caches and creates a CacheContext (without
|
| + // instantiating a backend) for each.
|
| + void LazyInit(const base::Closure& closure);
|
| +
|
| CacheContext* GetLoadedCache(const std::string& cache_name) const;
|
| + CacheContext* AddCacheToMaps(const std::string& cache_name,
|
| + scoped_ptr<ServiceWorkerCache> cache);
|
|
|
| - // Initializer and its callback are below.
|
| - void LazyInit(const base::Closure& closure);
|
| + // The initialization callbacks are below.
|
| static void LazyInitDidLoadIndex(
|
| const base::Closure& callback,
|
| base::WeakPtr<ServiceWorkerCacheStorage> storage,
|
| @@ -116,14 +121,6 @@ class CONTENT_EXPORT ServiceWorkerCacheStorage {
|
| scoped_ptr<ServiceWorkerCache> cache);
|
| static void LazyInitDone(base::WeakPtr<ServiceWorkerCacheStorage> storage);
|
|
|
| - static void DidCreateBackend(base::WeakPtr<ServiceWorkerCache> cache,
|
| - CacheID cache_id,
|
| - const CacheAndErrorCallback& callback,
|
| - ServiceWorkerCache::ErrorType error);
|
| -
|
| - CacheContext* AddCacheToMaps(const std::string& cache_name,
|
| - scoped_ptr<ServiceWorkerCache> cache);
|
| -
|
| // The CreateCache callbacks are below.
|
| static void CreateCacheDidCreateCache(
|
| const std::string& cache_name,
|
| @@ -144,6 +141,11 @@ class CONTENT_EXPORT ServiceWorkerCacheStorage {
|
| static void DeleteCacheDidCleanUp(const BoolAndErrorCallback& callback,
|
| bool success);
|
|
|
| + static void DidCreateBackend(base::WeakPtr<ServiceWorkerCache> cache,
|
| + CacheID cache_id,
|
| + const CacheAndErrorCallback& callback,
|
| + ServiceWorkerCache::ErrorType error);
|
| +
|
| // Whether or not we've loaded the list of cache names into memory.
|
| bool initialized_;
|
|
|
|
|