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

Unified Diff: public/web/WebServiceWorkerContextClient.h

Issue 900793002: ServiceWorker: Support SWRegistration.unregister() in SWGlobalScope [2/2] (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: update layout tests and header comment Created 5 years, 10 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
« no previous file with comments | « Source/web/WebEmbeddedWorkerImpl.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/web/WebServiceWorkerContextClient.h
diff --git a/public/web/WebServiceWorkerContextClient.h b/public/web/WebServiceWorkerContextClient.h
index 2f2980388d494294e890c60d34f37149c9f9cb34..b3f13b9fa253920c9d59037126b87c2d05ce8ea2 100644
--- a/public/web/WebServiceWorkerContextClient.h
+++ b/public/web/WebServiceWorkerContextClient.h
@@ -47,14 +47,15 @@ class WebDataSource;
class WebServiceWorkerCacheStorage;
class WebServiceWorkerContextProxy;
class WebServiceWorkerNetworkProvider;
+class WebServiceWorkerProvider;
class WebServiceWorkerResponse;
class WebString;
// This interface is implemented by the client. It is supposed to be created
-// on the main thread and then passed on to the worker thread.
-// by a newly created WorkerGlobalScope. All methods of this class, except
-// for createServiceWorkerNetworkProvider() and workerContextFailedToStart(),
+// on the main thread and then passed on to the worker thread by a newly
+// created WorkerGlobalScope. Unless otherwise noted, all methods of this class
// are called on the worker thread.
+//
// FIXME: Split this into EmbeddedWorkerContextClient and
// ServiceWorkerScriptContextClient when we decide to use EmbeddedWorker
// framework for other implementation (like SharedWorker).
@@ -63,7 +64,7 @@ public:
virtual ~WebServiceWorkerContextClient() { }
// ServiceWorker specific method.
- virtual WebServiceWorkerCacheStorage* cacheStorage() { return 0; }
+ virtual WebServiceWorkerCacheStorage* cacheStorage() { return nullptr; }
// ServiceWorker specific method. Called when script accesses the
// the |scope| attribute of the ServiceWorkerGlobalScope. Immutable per spec.
@@ -146,7 +147,12 @@ public:
virtual void didHandleCrossOriginConnectEvent(int connectEventID, bool acceptConnect) { }
// Ownership of the returned object is transferred to the caller.
- virtual WebServiceWorkerNetworkProvider* createServiceWorkerNetworkProvider(WebDataSource*) { return 0; }
+ // This is called on the main thread.
+ virtual WebServiceWorkerNetworkProvider* createServiceWorkerNetworkProvider(WebDataSource*) { return nullptr; }
+
+ // Ownership of the returned object is transferred to the caller.
+ // This is called on the main thread.
+ virtual WebServiceWorkerProvider* createServiceWorkerProvider() { return nullptr; }
// Ownership of the passed callbacks is transferred to the callee, callee
// should delete the callbacks after calling either onSuccess or onError.
« no previous file with comments | « Source/web/WebEmbeddedWorkerImpl.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698