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

Unified Diff: Source/modules/serviceworkers/ServiceWorkerGlobalScope.h

Issue 318393002: Initial implementation of ServiceWorkerGlobalScope.fetch() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: incoroporated dominicc's comment Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: Source/modules/serviceworkers/ServiceWorkerGlobalScope.h
diff --git a/Source/modules/serviceworkers/ServiceWorkerGlobalScope.h b/Source/modules/serviceworkers/ServiceWorkerGlobalScope.h
index 3fab81ffd66dff884b7c39248466b9e6c8ef3c22..fca77813cc9588e247fafe3cb2afd192990ba83f 100644
--- a/Source/modules/serviceworkers/ServiceWorkerGlobalScope.h
+++ b/Source/modules/serviceworkers/ServiceWorkerGlobalScope.h
@@ -36,6 +36,10 @@
namespace WebCore {
+class FetchManager;
+class Request;
+class ScriptPromise;
+class ScriptState;
class ServiceWorkerThread;
class ServiceWorkerClients;
class WorkerThreadStartupData;
@@ -46,10 +50,13 @@ public:
virtual ~ServiceWorkerGlobalScope();
virtual bool isServiceWorkerGlobalScope() const OVERRIDE { return true; }
+ virtual void stopFetch() OVERRIDE;
// ServiceWorkerGlobalScope.idl
PassRefPtr<ServiceWorkerClients> clients();
String scope(ExecutionContext*);
+ ScriptPromise fetch(ScriptState*, Request*);
+ ScriptPromise fetch(ScriptState*, const String&);
// EventTarget
virtual const AtomicString& interfaceName() const OVERRIDE;
@@ -66,6 +73,7 @@ private:
ServiceWorkerGlobalScope(const KURL&, const String& userAgent, ServiceWorkerThread*, double timeOrigin, PassOwnPtrWillBeRawPtr<WorkerClients>);
RefPtr<ServiceWorkerClients> m_clients;
+ OwnPtr<FetchManager> m_fetchManager;
};
} // namespace WebCore
« no previous file with comments | « Source/modules/serviceworkers/Request.cpp ('k') | Source/modules/serviceworkers/ServiceWorkerGlobalScope.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698