OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_RENDERER_CACHE_STORAGE_CACHE_STORAGE_DISPATCHER_H_ | 5 #ifndef CONTENT_RENDERER_CACHE_STORAGE_CACHE_STORAGE_DISPATCHER_H_ |
6 #define CONTENT_RENDERER_CACHE_STORAGE_CACHE_STORAGE_DISPATCHER_H_ | 6 #define CONTENT_RENDERER_CACHE_STORAGE_CACHE_STORAGE_DISPATCHER_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/id_map.h" | 10 #include "base/id_map.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
13 #include "base/strings/string16.h" | 13 #include "base/strings/string16.h" |
14 #include "base/time/time.h" | 14 #include "base/time/time.h" |
15 #include "content/child/worker_task_runner.h" | 15 #include "content/child/worker_task_runner.h" |
16 #include "content/public/renderer/render_process_observer.h" | 16 #include "content/public/renderer/render_process_observer.h" |
17 #include "third_party/WebKit/public/platform/WebServiceWorkerCache.h" | 17 #include "third_party/WebKit/public/platform/modules/serviceworker/WebServiceWor
kerCache.h" |
18 #include "third_party/WebKit/public/platform/WebServiceWorkerCacheError.h" | 18 #include "third_party/WebKit/public/platform/modules/serviceworker/WebServiceWor
kerCacheError.h" |
19 #include "third_party/WebKit/public/platform/WebServiceWorkerCacheStorage.h" | 19 #include "third_party/WebKit/public/platform/modules/serviceworker/WebServiceWor
kerCacheStorage.h" |
20 | 20 |
21 namespace content { | 21 namespace content { |
22 | 22 |
23 class ThreadSafeSender; | 23 class ThreadSafeSender; |
24 struct ServiceWorkerFetchRequest; | 24 struct ServiceWorkerFetchRequest; |
25 struct ServiceWorkerResponse; | 25 struct ServiceWorkerResponse; |
26 | 26 |
27 // Handle the Cache Storage messaging for this context thread. The | 27 // Handle the Cache Storage messaging for this context thread. The |
28 // main thread and each worker thread have their own instances. | 28 // main thread and each worker thread have their own instances. |
29 class CacheStorageDispatcher : public WorkerTaskRunner::Observer { | 29 class CacheStorageDispatcher : public WorkerTaskRunner::Observer { |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 TimeMap cache_batch_times_; | 214 TimeMap cache_batch_times_; |
215 | 215 |
216 base::WeakPtrFactory<CacheStorageDispatcher> weak_factory_; | 216 base::WeakPtrFactory<CacheStorageDispatcher> weak_factory_; |
217 | 217 |
218 DISALLOW_COPY_AND_ASSIGN(CacheStorageDispatcher); | 218 DISALLOW_COPY_AND_ASSIGN(CacheStorageDispatcher); |
219 }; | 219 }; |
220 | 220 |
221 } // namespace content | 221 } // namespace content |
222 | 222 |
223 #endif // CONTENT_RENDERER_CACHE_STORAGE_CACHE_STORAGE_DISPATCHER_H_ | 223 #endif // CONTENT_RENDERER_CACHE_STORAGE_CACHE_STORAGE_DISPATCHER_H_ |
OLD | NEW |