OLD | NEW |
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_CHILD_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_H_ | 5 #ifndef CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_H_ |
6 #define CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_H_ | 6 #define CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 RegistrationObjectMap; | 122 RegistrationObjectMap; |
123 | 123 |
124 friend class WebServiceWorkerImpl; | 124 friend class WebServiceWorkerImpl; |
125 friend class WebServiceWorkerRegistrationImpl; | 125 friend class WebServiceWorkerRegistrationImpl; |
126 | 126 |
127 // WorkerTaskRunner::Observer implementation. | 127 // WorkerTaskRunner::Observer implementation. |
128 virtual void OnWorkerRunLoopStopped() OVERRIDE; | 128 virtual void OnWorkerRunLoopStopped() OVERRIDE; |
129 | 129 |
130 void OnRegistered(int thread_id, | 130 void OnRegistered(int thread_id, |
131 int request_id, | 131 int request_id, |
132 const ServiceWorkerRegistrationObjectInfo& info); | 132 const ServiceWorkerRegistrationObjectInfo& info, |
| 133 const ServiceWorkerVersionAttributes& attrs); |
133 void OnUnregistered(int thread_id, | 134 void OnUnregistered(int thread_id, |
134 int request_id); | 135 int request_id); |
135 void OnRegistrationError(int thread_id, | 136 void OnRegistrationError(int thread_id, |
136 int request_id, | 137 int request_id, |
137 blink::WebServiceWorkerError::ErrorType error_type, | 138 blink::WebServiceWorkerError::ErrorType error_type, |
138 const base::string16& message); | 139 const base::string16& message); |
139 void OnServiceWorkerStateChanged(int thread_id, | 140 void OnServiceWorkerStateChanged(int thread_id, |
140 int handle_id, | 141 int handle_id, |
141 blink::WebServiceWorkerState state); | 142 blink::WebServiceWorkerState state); |
142 void OnSetVersionAttributes(int thread_id, | 143 void OnSetVersionAttributes(int thread_id, |
143 int provider_id, | 144 int provider_id, |
144 int registration_handle_id, | 145 int registration_handle_id, |
145 int changed_mask, | 146 int changed_mask, |
146 const ServiceWorkerVersionAttributes& attributes); | 147 const ServiceWorkerVersionAttributes& attributes); |
| 148 void OnUpdateFound(int thread_id, |
| 149 const ServiceWorkerRegistrationObjectInfo& info); |
147 void OnSetControllerServiceWorker(int thread_id, | 150 void OnSetControllerServiceWorker(int thread_id, |
148 int provider_id, | 151 int provider_id, |
149 const ServiceWorkerObjectInfo& info); | 152 const ServiceWorkerObjectInfo& info); |
150 void OnPostMessage(int thread_id, | 153 void OnPostMessage(int thread_id, |
151 int provider_id, | 154 int provider_id, |
152 const base::string16& message, | 155 const base::string16& message, |
153 const std::vector<int>& sent_message_port_ids, | 156 const std::vector<int>& sent_message_port_ids, |
154 const std::vector<int>& new_routing_ids); | 157 const std::vector<int>& new_routing_ids); |
155 | 158 |
156 void SetInstallingServiceWorker( | 159 void SetInstallingServiceWorker( |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 WorkerToProviderMap worker_to_provider_; | 191 WorkerToProviderMap worker_to_provider_; |
189 | 192 |
190 scoped_refptr<ThreadSafeSender> thread_safe_sender_; | 193 scoped_refptr<ThreadSafeSender> thread_safe_sender_; |
191 | 194 |
192 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcher); | 195 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcher); |
193 }; | 196 }; |
194 | 197 |
195 } // namespace content | 198 } // namespace content |
196 | 199 |
197 #endif // CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_H_ | 200 #endif // CONTENT_CHILD_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_H_ |
OLD | NEW |