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 CacheStorage_h | 5 #ifndef CacheStorage_h |
6 #define CacheStorage_h | 6 #define CacheStorage_h |
7 | 7 |
8 #include "bindings/core/v8/ScriptPromise.h" | 8 #include "bindings/core/v8/ScriptPromise.h" |
9 #include "bindings/core/v8/ScriptState.h" | 9 #include "bindings/core/v8/ScriptState.h" |
10 #include "bindings/core/v8/ScriptWrappable.h" | 10 #include "bindings/core/v8/ScriptWrappable.h" |
(...skipping 14 matching lines...) Expand all Loading... | |
25 WTF_MAKE_NONCOPYABLE(CacheStorage); | 25 WTF_MAKE_NONCOPYABLE(CacheStorage); |
26 public: | 26 public: |
27 static CacheStorage* create(WebServiceWorkerCacheStorage*); | 27 static CacheStorage* create(WebServiceWorkerCacheStorage*); |
28 | 28 |
29 ScriptPromise open(ScriptState*, const String& cacheName); | 29 ScriptPromise open(ScriptState*, const String& cacheName); |
30 ScriptPromise has(ScriptState*, const String& cacheName); | 30 ScriptPromise has(ScriptState*, const String& cacheName); |
31 ScriptPromise deleteFunction(ScriptState*, const String& cacheName); | 31 ScriptPromise deleteFunction(ScriptState*, const String& cacheName); |
32 ScriptPromise keys(ScriptState*); | 32 ScriptPromise keys(ScriptState*); |
33 ScriptPromise match(ScriptState*, const RequestInfo&, const CacheQueryOption s&, ExceptionState&); | 33 ScriptPromise match(ScriptState*, const RequestInfo&, const CacheQueryOption s&, ExceptionState&); |
34 | 34 |
35 WebServiceWorkerCacheStorage* webCacheStorage() const { return m_webCacheSto rage.get(); } | |
pfeldman
2015/04/16 10:22:53
I thought this was no longer necessary.
dmurph
2015/04/18 00:59:32
Bad merge, removed.
| |
35 | 36 |
36 DECLARE_TRACE(); | 37 DECLARE_TRACE(); |
37 | 38 |
38 private: | 39 private: |
39 class Callbacks; | 40 class Callbacks; |
40 class WithCacheCallbacks; | 41 class WithCacheCallbacks; |
41 class DeleteCallbacks; | 42 class DeleteCallbacks; |
42 class KeysCallbacks; | 43 class KeysCallbacks; |
43 class MatchCallbacks; | 44 class MatchCallbacks; |
44 | 45 |
45 friend class WithCacheCallbacks; | 46 friend class WithCacheCallbacks; |
46 friend class DeleteCallbacks; | 47 friend class DeleteCallbacks; |
47 | 48 |
48 explicit CacheStorage(PassOwnPtr<WebServiceWorkerCacheStorage>); | 49 explicit CacheStorage(PassOwnPtr<WebServiceWorkerCacheStorage>); |
49 ScriptPromise matchImpl(ScriptState*, const Request*, const CacheQueryOption s&); | 50 ScriptPromise matchImpl(ScriptState*, const Request*, const CacheQueryOption s&); |
50 | 51 |
51 OwnPtr<WebServiceWorkerCacheStorage> m_webCacheStorage; | 52 OwnPtr<WebServiceWorkerCacheStorage> m_webCacheStorage; |
52 HeapHashMap<String, Member<Cache>> m_nameToCacheMap; | 53 HeapHashMap<String, Member<Cache>> m_nameToCacheMap; |
53 }; | 54 }; |
54 | 55 |
55 } // namespace blink | 56 } // namespace blink |
56 | 57 |
57 #endif // CacheStorage_h | 58 #endif // CacheStorage_h |
OLD | NEW |