Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(681)

Side by Side Diff: third_party/WebKit/Source/modules/background_fetch/ServiceWorkerRegistrationBackgroundFetch.h

Issue 2736143003: Introduce the Background Fetch module. (Closed)
Patch Set: more webexposed tests Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef ServiceWorkerRegistrationBackgroundFetch_h
6 #define ServiceWorkerRegistrationBackgroundFetch_h
7
8 #include "modules/serviceworkers/ServiceWorkerRegistration.h"
9 #include "platform/Supplementable.h"
10 #include "platform/heap/GarbageCollected.h"
11 #include "platform/heap/Handle.h"
12
13 namespace blink {
14
15 class BackgroundFetchManager;
16
17 class ServiceWorkerRegistrationBackgroundFetch final
18 : public GarbageCollectedFinalized<
19 ServiceWorkerRegistrationBackgroundFetch>,
20 public Supplement<ServiceWorkerRegistration> {
21 USING_GARBAGE_COLLECTED_MIXIN(ServiceWorkerRegistrationBackgroundFetch);
22 WTF_MAKE_NONCOPYABLE(ServiceWorkerRegistrationBackgroundFetch);
23
24 public:
25 virtual ~ServiceWorkerRegistrationBackgroundFetch();
26
27 static ServiceWorkerRegistrationBackgroundFetch& from(
28 ServiceWorkerRegistration&);
29
30 static BackgroundFetchManager* backgroundFetch(ServiceWorkerRegistration&);
31 BackgroundFetchManager* backgroundFetch();
32
33 DECLARE_VIRTUAL_TRACE();
34
35 private:
36 explicit ServiceWorkerRegistrationBackgroundFetch(ServiceWorkerRegistration*);
37 static const char* supplementName();
38
39 Member<ServiceWorkerRegistration> m_registration;
40 Member<BackgroundFetchManager> m_backgroundFetchManager;
41 };
42
43 } // namespace blink
44
45 #endif // ServiceWorkerRegistrationBackgroundFetch_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698