Index: content/browser/service_worker/embedded_worker_instance.h |
diff --git a/content/browser/service_worker/embedded_worker_instance.h b/content/browser/service_worker/embedded_worker_instance.h |
index 2304a48ec3529fd86480edb67dd5150b95ac967c..c3215c8ed56970bb8e5879b90c655fbff0971607 100644 |
--- a/content/browser/service_worker/embedded_worker_instance.h |
+++ b/content/browser/service_worker/embedded_worker_instance.h |
@@ -37,6 +37,8 @@ namespace content { |
class EmbeddedWorkerRegistry; |
class MessagePortMessageFilter; |
+class ServiceRegistry; |
+class ServiceRegistryImpl; |
class ServiceWorkerContextCore; |
struct ServiceWorkerFetchRequest; |
@@ -120,6 +122,10 @@ class CONTENT_EXPORT EmbeddedWorkerInstance { |
// status. |
ServiceWorkerStatusCode SendMessage(const IPC::Message& message); |
+ // Returns the ServiceRegistry for this worker. It is invalid to call this |
+ // when the worker is not in STARTING or RUNNING status. |
+ ServiceRegistry* GetServiceRegistry(); |
+ |
void ResumeAfterDownload(); |
int embedded_worker_id() const { return embedded_worker_id_; } |
@@ -241,6 +247,7 @@ class CONTENT_EXPORT EmbeddedWorkerInstance { |
// Current running information. -1 indicates the worker is not running. |
int process_id_; |
int thread_id_; |
+ scoped_ptr<ServiceRegistryImpl> service_registry_; |
// Whether devtools is attached or not. |
bool devtools_attached_; |