diff options
Diffstat (limited to 'webkit/appcache/appcache_storage.h')
-rw-r--r-- | webkit/appcache/appcache_storage.h | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/webkit/appcache/appcache_storage.h b/webkit/appcache/appcache_storage.h index 7df1580..7aab17f 100644 --- a/webkit/appcache/appcache_storage.h +++ b/webkit/appcache/appcache_storage.h @@ -66,7 +66,7 @@ class APPCACHE_EXPORT AppCacheStorage { virtual void OnMainResponseFound( const GURL& url, const AppCacheEntry& entry, const GURL& fallback_url, const AppCacheEntry& fallback_entry, - int64 cache_id, const GURL& mainfest_url) {} + int64 cache_id, int64 group_id, const GURL& mainfest_url) {} }; explicit AppCacheStorage(AppCacheService* service); @@ -98,7 +98,8 @@ class APPCACHE_EXPORT AppCacheStorage { // immediately without returning to the message loop. If the load fails, // the delegate will be called back with a NULL pointer. virtual void LoadResponseInfo( - const GURL& manifest_url, int64 response_id, Delegate* delegate); + const GURL& manifest_url, int64 group_id, int64 response_id, + Delegate* delegate); // Schedules a group and its newest complete cache to be initially stored or // incrementally updated with new changes. Upon completion the delegate @@ -150,12 +151,12 @@ class APPCACHE_EXPORT AppCacheStorage { // Creates a reader to read a response from storage. virtual AppCacheResponseReader* CreateResponseReader( - const GURL& manifest_url, int64 response_id) = 0; + const GURL& manifest_url, int64 group_id, int64 response_id) = 0; // Creates a writer to write a new response to storage. This call // establishes a new response id. virtual AppCacheResponseWriter* CreateResponseWriter( - const GURL& manifest_url) = 0; + const GURL& manifest_url, int64 group_id) = 0; // Schedules the lazy deletion of responses and saves the ids // persistently such that the responses will be deleted upon restart @@ -229,12 +230,13 @@ class APPCACHE_EXPORT AppCacheStorage { // multiple callers. class ResponseInfoLoadTask { public: - ResponseInfoLoadTask(const GURL& manifest_url, int64 response_id, - AppCacheStorage* storage); + ResponseInfoLoadTask(const GURL& manifest_url, int64 group_id, + int64 response_id, AppCacheStorage* storage); ~ResponseInfoLoadTask(); int64 response_id() const { return response_id_; } const GURL& manifest_url() const { return manifest_url_; } + int64 group_id() const { return group_id_; } void AddDelegate(DelegateReference* delegate_reference) { delegates_.push_back(delegate_reference); @@ -247,6 +249,7 @@ class APPCACHE_EXPORT AppCacheStorage { AppCacheStorage* storage_; GURL manifest_url_; + int64 group_id_; int64 response_id_; scoped_ptr<AppCacheResponseReader> reader_; DelegateReferenceVector delegates_; @@ -272,12 +275,12 @@ class APPCACHE_EXPORT AppCacheStorage { } ResponseInfoLoadTask* GetOrCreateResponseInfoLoadTask( - const GURL& manifest_url, int64 response_id) { + const GURL& manifest_url, int64 group_id, int64 response_id) { PendingResponseInfoLoads::iterator iter = pending_info_loads_.find(response_id); if (iter != pending_info_loads_.end()) return iter->second; - return new ResponseInfoLoadTask(manifest_url, response_id, this); + return new ResponseInfoLoadTask(manifest_url, group_id, response_id, this); } // Should only be called when creating a new response writer. |