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 Cache_h | 5 #ifndef Cache_h |
6 #define Cache_h | 6 #define Cache_h |
7 | 7 |
8 #include "bindings/core/v8/ScriptPromise.h" | 8 #include "bindings/core/v8/ScriptPromise.h" |
9 #include "bindings/core/v8/ScriptWrappable.h" | 9 #include "bindings/core/v8/ScriptWrappable.h" |
10 #include "core/dom/DOMException.h" | 10 #include "core/dom/DOMException.h" |
11 #include "modules/serviceworkers/CacheQueryOptions.h" | 11 #include "modules/serviceworkers/CacheQueryOptions.h" |
12 #include "public/platform/WebServiceWorkerCache.h" | 12 #include "public/platform/WebServiceWorkerCache.h" |
13 #include "public/platform/WebServiceWorkerCacheError.h" | 13 #include "public/platform/WebServiceWorkerCacheError.h" |
14 #include "wtf/Forward.h" | 14 #include "wtf/Forward.h" |
15 #include "wtf/Noncopyable.h" | 15 #include "wtf/Noncopyable.h" |
16 #include "wtf/OwnPtr.h" | 16 #include "wtf/OwnPtr.h" |
17 #include "wtf/Vector.h" | 17 #include "wtf/Vector.h" |
18 #include "wtf/text/WTFString.h" | 18 #include "wtf/text/WTFString.h" |
19 | 19 |
20 namespace blink { | 20 namespace blink { |
21 | 21 |
22 class Response; | 22 class Response; |
23 class Request; | 23 class Request; |
24 class ScriptState; | 24 class ScriptState; |
25 | 25 |
26 class Cache FINAL : public GarbageCollectedFinalized<Cache>, public ScriptWrappa
ble { | 26 class Cache final : public GarbageCollectedFinalized<Cache>, public ScriptWrappa
ble { |
27 DEFINE_WRAPPERTYPEINFO(); | 27 DEFINE_WRAPPERTYPEINFO(); |
28 WTF_MAKE_NONCOPYABLE(Cache); | 28 WTF_MAKE_NONCOPYABLE(Cache); |
29 public: | 29 public: |
30 static Cache* create(WebServiceWorkerCache*); | 30 static Cache* create(WebServiceWorkerCache*); |
31 | 31 |
32 // From Cache.idl: | 32 // From Cache.idl: |
33 ScriptPromise match(ScriptState*, Request*, const CacheQueryOptions&); | 33 ScriptPromise match(ScriptState*, Request*, const CacheQueryOptions&); |
34 ScriptPromise match(ScriptState*, const String&, const CacheQueryOptions&); | 34 ScriptPromise match(ScriptState*, const String&, const CacheQueryOptions&); |
35 ScriptPromise matchAll(ScriptState*, Request*, const CacheQueryOptions&); | 35 ScriptPromise matchAll(ScriptState*, Request*, const CacheQueryOptions&); |
36 ScriptPromise matchAll(ScriptState*, const String&, const CacheQueryOptions&
); | 36 ScriptPromise matchAll(ScriptState*, const String&, const CacheQueryOptions&
); |
(...skipping 23 matching lines...) Expand all Loading... |
60 ScriptPromise putImpl(ScriptState*, Request*, Response*); | 60 ScriptPromise putImpl(ScriptState*, Request*, Response*); |
61 ScriptPromise keysImpl(ScriptState*); | 61 ScriptPromise keysImpl(ScriptState*); |
62 ScriptPromise keysImpl(ScriptState*, Request*, const CacheQueryOptions&); | 62 ScriptPromise keysImpl(ScriptState*, Request*, const CacheQueryOptions&); |
63 | 63 |
64 OwnPtr<WebServiceWorkerCache> m_webCache; | 64 OwnPtr<WebServiceWorkerCache> m_webCache; |
65 }; | 65 }; |
66 | 66 |
67 } // namespace blink | 67 } // namespace blink |
68 | 68 |
69 #endif // Cache_h | 69 #endif // Cache_h |
OLD | NEW |