| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ | 5 #ifndef CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ |
| 6 #define CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ | 6 #define CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 | 80 |
| 81 // Called some time after the worker has started. Attempts to use the | 81 // Called some time after the worker has started. Attempts to use the |
| 82 // ServiceRegistry to connect to services before this method is called are | 82 // ServiceRegistry to connect to services before this method is called are |
| 83 // queued up and will resolve after this method is called. | 83 // queued up and will resolve after this method is called. |
| 84 void BindServiceRegistry( | 84 void BindServiceRegistry( |
| 85 mojo::InterfaceRequest<mojo::ServiceProvider> services, | 85 mojo::InterfaceRequest<mojo::ServiceProvider> services, |
| 86 mojo::ServiceProviderPtr exposed_services); | 86 mojo::ServiceProviderPtr exposed_services); |
| 87 | 87 |
| 88 // WebServiceWorkerContextClient overrides. | 88 // WebServiceWorkerContextClient overrides. |
| 89 blink::WebURL scope() const override; | 89 blink::WebURL scope() const override; |
| 90 void getClient(const blink::WebString&, |
| 91 blink::WebServiceWorkerClientCallbacks*) override; |
| 90 void getClients(const blink::WebServiceWorkerClientQueryOptions&, | 92 void getClients(const blink::WebServiceWorkerClientQueryOptions&, |
| 91 blink::WebServiceWorkerClientsCallbacks*) override; | 93 blink::WebServiceWorkerClientsCallbacks*) override; |
| 92 void openWindow(const blink::WebURL&, | 94 void openWindow(const blink::WebURL&, |
| 93 blink::WebServiceWorkerClientCallbacks*) override; | 95 blink::WebServiceWorkerClientCallbacks*) override; |
| 94 void setCachedMetadata(const blink::WebURL&, | 96 void setCachedMetadata(const blink::WebURL&, |
| 95 const char* data, | 97 const char* data, |
| 96 size_t size) override; | 98 size_t size) override; |
| 97 void clearCachedMetadata(const blink::WebURL&) override; | 99 void clearCachedMetadata(const blink::WebURL&) override; |
| 98 void workerReadyForInspection() override; | 100 void workerReadyForInspection() override; |
| 99 | 101 |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 195 const blink::WebCircularGeofencingRegion& region); | 197 const blink::WebCircularGeofencingRegion& region); |
| 196 void OnPostMessage( | 198 void OnPostMessage( |
| 197 const base::string16& message, | 199 const base::string16& message, |
| 198 const std::vector<TransferredMessagePort>& sent_message_ports, | 200 const std::vector<TransferredMessagePort>& sent_message_ports, |
| 199 const std::vector<int>& new_routing_ids); | 201 const std::vector<int>& new_routing_ids); |
| 200 void OnCrossOriginMessageToWorker( | 202 void OnCrossOriginMessageToWorker( |
| 201 const NavigatorConnectClient& client, | 203 const NavigatorConnectClient& client, |
| 202 const base::string16& message, | 204 const base::string16& message, |
| 203 const std::vector<TransferredMessagePort>& sent_message_ports, | 205 const std::vector<TransferredMessagePort>& sent_message_ports, |
| 204 const std::vector<int>& new_routing_ids); | 206 const std::vector<int>& new_routing_ids); |
| 207 void OnDidGetClient(int request_id, const ServiceWorkerClientInfo& client); |
| 205 void OnDidGetClients( | 208 void OnDidGetClients( |
| 206 int request_id, const std::vector<ServiceWorkerClientInfo>& clients); | 209 int request_id, const std::vector<ServiceWorkerClientInfo>& clients); |
| 207 void OnOpenWindowResponse(int request_id, | 210 void OnOpenWindowResponse(int request_id, |
| 208 const ServiceWorkerClientInfo& client); | 211 const ServiceWorkerClientInfo& client); |
| 209 void OnOpenWindowError(int request_id, const std::string& message); | 212 void OnOpenWindowError(int request_id, const std::string& message); |
| 210 void OnFocusClientResponse(int request_id, | 213 void OnFocusClientResponse(int request_id, |
| 211 const ServiceWorkerClientInfo& client); | 214 const ServiceWorkerClientInfo& client); |
| 212 void OnNavigateClientResponse(int request_id, | 215 void OnNavigateClientResponse(int request_id, |
| 213 const ServiceWorkerClientInfo& client); | 216 const ServiceWorkerClientInfo& client); |
| 214 void OnNavigateClientError(int request_id, const GURL& url); | 217 void OnNavigateClientError(int request_id, const GURL& url); |
| (...skipping 23 matching lines...) Expand all Loading... |
| 238 // Initialized on the worker thread in workerContextStarted and | 241 // Initialized on the worker thread in workerContextStarted and |
| 239 // destructed on the worker thread in willDestroyWorkerContext. | 242 // destructed on the worker thread in willDestroyWorkerContext. |
| 240 scoped_ptr<WorkerContextData> context_; | 243 scoped_ptr<WorkerContextData> context_; |
| 241 | 244 |
| 242 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerContextClient); | 245 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerContextClient); |
| 243 }; | 246 }; |
| 244 | 247 |
| 245 } // namespace content | 248 } // namespace content |
| 246 | 249 |
| 247 #endif // CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ | 250 #endif // CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ |
| OLD | NEW |