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

Side by Side Diff: content/browser/service_worker/service_worker_dispatcher_host.h

Issue 1175823002: ServiceWorker: Implement ServiceWorkerRegistration.update() (2) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/id_map.h" 10 #include "base/id_map.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 friend class BrowserThread; 80 friend class BrowserThread;
81 friend class base::DeleteHelper<ServiceWorkerDispatcherHost>; 81 friend class base::DeleteHelper<ServiceWorkerDispatcherHost>;
82 friend class TestingServiceWorkerDispatcherHost; 82 friend class TestingServiceWorkerDispatcherHost;
83 83
84 // IPC Message handlers 84 // IPC Message handlers
85 void OnRegisterServiceWorker(int thread_id, 85 void OnRegisterServiceWorker(int thread_id,
86 int request_id, 86 int request_id,
87 int provider_id, 87 int provider_id,
88 const GURL& pattern, 88 const GURL& pattern,
89 const GURL& script_url); 89 const GURL& script_url);
90 void OnUpdateServiceWorker(int provider_id, const GURL& pattern);
90 void OnUnregisterServiceWorker(int thread_id, 91 void OnUnregisterServiceWorker(int thread_id,
91 int request_id, 92 int request_id,
92 int provider_id, 93 int provider_id,
93 const GURL& pattern); 94 const GURL& pattern);
94 void OnGetRegistration(int thread_id, 95 void OnGetRegistration(int thread_id,
95 int request_id, 96 int request_id,
96 int provider_id, 97 int provider_id,
97 const GURL& document_url); 98 const GURL& document_url);
98 void OnGetRegistrationForReady(int thread_id, 99 void OnGetRegistrationForReady(int thread_id,
99 int request_id, 100 int request_id,
(...skipping 24 matching lines...) Expand all
124 void OnDecrementServiceWorkerRefCount(int handle_id); 125 void OnDecrementServiceWorkerRefCount(int handle_id);
125 void OnIncrementRegistrationRefCount(int registration_handle_id); 126 void OnIncrementRegistrationRefCount(int registration_handle_id);
126 void OnDecrementRegistrationRefCount(int registration_handle_id); 127 void OnDecrementRegistrationRefCount(int registration_handle_id);
127 void OnPostMessageToWorker( 128 void OnPostMessageToWorker(
128 int handle_id, 129 int handle_id,
129 const base::string16& message, 130 const base::string16& message,
130 const std::vector<TransferredMessagePort>& sent_message_ports); 131 const std::vector<TransferredMessagePort>& sent_message_ports);
131 void OnServiceWorkerObjectDestroyed(int handle_id); 132 void OnServiceWorkerObjectDestroyed(int handle_id);
132 void OnTerminateWorker(int handle_id); 133 void OnTerminateWorker(int handle_id);
133 134
135 void DidFindRegistrationForUpdate(
136 ServiceWorkerStatusCode status,
137 const scoped_refptr<ServiceWorkerRegistration>& registration);
138
134 ServiceWorkerRegistrationHandle* FindRegistrationHandle( 139 ServiceWorkerRegistrationHandle* FindRegistrationHandle(
135 int provider_id, 140 int provider_id,
136 int64 registration_id); 141 int64 registration_id);
137 142
138 void GetRegistrationObjectInfoAndVersionAttributes( 143 void GetRegistrationObjectInfoAndVersionAttributes(
139 base::WeakPtr<ServiceWorkerProviderHost> provider_host, 144 base::WeakPtr<ServiceWorkerProviderHost> provider_host,
140 ServiceWorkerRegistration* registration, 145 ServiceWorkerRegistration* registration,
141 ServiceWorkerRegistrationObjectInfo* info, 146 ServiceWorkerRegistrationObjectInfo* info,
142 ServiceWorkerVersionAttributes* attrs); 147 ServiceWorkerVersionAttributes* attrs);
143 148
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 196
192 bool channel_ready_; // True after BrowserMessageFilter::sender_ != NULL. 197 bool channel_ready_; // True after BrowserMessageFilter::sender_ != NULL.
193 ScopedVector<IPC::Message> pending_messages_; 198 ScopedVector<IPC::Message> pending_messages_;
194 199
195 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost); 200 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost);
196 }; 201 };
197 202
198 } // namespace content 203 } // namespace content
199 204
200 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ 205 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698