Index: third_party/WebKit/Source/modules/background_fetch/BackgroundFetchManager.h |
diff --git a/third_party/WebKit/Source/modules/background_fetch/BackgroundFetchManager.h b/third_party/WebKit/Source/modules/background_fetch/BackgroundFetchManager.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..67d18198a0b02d4b373a60c410eb68a1c0a777f3 |
--- /dev/null |
+++ b/third_party/WebKit/Source/modules/background_fetch/BackgroundFetchManager.h |
@@ -0,0 +1,43 @@ |
+// Copyright 2017 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef BackgroundFetchManager_h |
+#define BackgroundFetchManager_h |
+ |
+#include "bindings/core/v8/ScriptPromise.h" |
+#include "bindings/core/v8/ScriptWrappable.h" |
+#include "platform/heap/GarbageCollected.h" |
+#include "platform/heap/Handle.h" |
+ |
+namespace blink { |
+ |
+class ScriptState; |
+class ServiceWorkerRegistration; |
+ |
+// Implementation of the BackgroundFetchManager JavaScript object, accessible |
+// by developers through ServiceWorkerRegistration.backgroundFetch. |
+class BackgroundFetchManager final |
+ : public GarbageCollected<BackgroundFetchManager>, |
+ public ScriptWrappable { |
+ DEFINE_WRAPPERTYPEINFO(); |
+ |
+ public: |
+ static BackgroundFetchManager* create( |
+ ServiceWorkerRegistration* registration) { |
+ return new BackgroundFetchManager(registration); |
+ } |
+ |
+ ScriptPromise getTags(ScriptState*); |
+ |
+ DECLARE_TRACE(); |
+ |
+ private: |
+ explicit BackgroundFetchManager(ServiceWorkerRegistration*); |
+ |
+ Member<ServiceWorkerRegistration> m_registration; |
+}; |
+ |
+} // namespace blink |
+ |
+#endif // BackgroundFetchManager_h |