| 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/v8/ScriptState.h" |
| 8 #include "bindings/v8/ScriptWrappable.h" | 9 #include "bindings/v8/ScriptWrappable.h" |
| 9 #include "wtf/Forward.h" | 10 #include "wtf/Forward.h" |
| 10 #include "wtf/PassRefPtr.h" | 11 #include "wtf/PassRefPtr.h" |
| 11 #include "wtf/RefCounted.h" | 12 #include "wtf/RefCounted.h" |
| 12 #include "wtf/Vector.h" | 13 #include "wtf/Vector.h" |
| 13 | 14 |
| 14 namespace WebCore { | 15 namespace WebCore { |
| 15 | 16 |
| 16 class ExecutionContext; | 17 class ExecutionContext; |
| 17 class ScriptPromise; | 18 class ScriptPromise; |
| 18 | 19 |
| 19 class Cache FINAL : public RefCounted<Cache>, public ScriptWrappable { | 20 class Cache FINAL : public RefCounted<Cache>, public ScriptWrappable { |
| 20 public: | 21 public: |
| 21 static PassRefPtr<Cache> create(const Vector<String>& urlStrings); | 22 static PassRefPtr<Cache> create(const Vector<String>& urlStrings); |
| 22 ~Cache(); | 23 ~Cache(); |
| 23 | 24 |
| 24 ScriptPromise match(ExecutionContext*, const String& urlString); | 25 ScriptPromise match(ScriptState*, const String& urlString); |
| 25 ScriptPromise ready(ExecutionContext*); | 26 ScriptPromise ready(ScriptState*); |
| 26 | 27 |
| 27 private: | 28 private: |
| 28 Cache(); | 29 Cache(); |
| 29 }; | 30 }; |
| 30 | 31 |
| 31 } // namespace WebCore | 32 } // namespace WebCore |
| 32 | 33 |
| 33 #endif // Cache_h | 34 #endif // Cache_h |
| OLD | NEW |