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

Unified Diff: content/browser/service_worker/service_worker_client_utils.h

Issue 1439333002: Service Worker: Add Clients.get(id) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Filter out off-origin match; fix layout test Created 4 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
Index: content/browser/service_worker/service_worker_client_utils.h
diff --git a/content/browser/service_worker/service_worker_client_utils.h b/content/browser/service_worker/service_worker_client_utils.h
index 258268e1e0d2cbe93c698a3970add5fddb7fd2a8..66a1b25269f38dc4f0e380c718d59979ad76e5cd 100644
--- a/content/browser/service_worker/service_worker_client_utils.h
+++ b/content/browser/service_worker/service_worker_client_utils.h
@@ -10,6 +10,7 @@
#include "base/callback.h"
#include "base/memory/weak_ptr.h"
+#include "content/browser/service_worker/service_worker_provider_host.h"
#include "content/common/service_worker/service_worker_status_code.h"
class GURL;
@@ -47,6 +48,14 @@ void NavigateClient(const GURL& url,
const base::WeakPtr<ServiceWorkerContextCore>& context,
const NavigationCallback& callback);
+// Gets a client matched by |client_uuid|. |callback| is called with the client
+// information on completion.
+void GetClient(
+ const base::WeakPtr<ServiceWorkerVersion>& controller,
+ const std::string& client_uuid,
+ const base::WeakPtr<ServiceWorkerContextCore>& context,
+ const ServiceWorkerProviderHost::GetClientInfoCallback& callback);
+
// Collects clients matched with |options|. |callback| is called with the client
// information sorted in MRU order (most recently focused order) on completion.
void GetClients(const base::WeakPtr<ServiceWorkerVersion>& controller,

Powered by Google App Engine
This is Rietveld 408576698