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

Side by Side Diff: content/renderer/service_worker/service_worker_context_client.h

Issue 1439333002: Service Worker: Add Clients.get(id) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove unnecessary condition 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 unified diff | Download patch
OLDNEW
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 <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 85
86 // Called some time after the worker has started. Attempts to use the 86 // Called some time after the worker has started. Attempts to use the
87 // ServiceRegistry to connect to services before this method is called are 87 // ServiceRegistry to connect to services before this method is called are
88 // queued up and will resolve after this method is called. 88 // queued up and will resolve after this method is called.
89 void BindServiceRegistry( 89 void BindServiceRegistry(
90 mojo::shell::mojom::InterfaceProviderRequest services, 90 mojo::shell::mojom::InterfaceProviderRequest services,
91 mojo::shell::mojom::InterfaceProviderPtr exposed_services); 91 mojo::shell::mojom::InterfaceProviderPtr exposed_services);
92 92
93 // WebServiceWorkerContextClient overrides. 93 // WebServiceWorkerContextClient overrides.
94 blink::WebURL scope() const override; 94 blink::WebURL scope() const override;
95 void getClient(const blink::WebString&,
96 blink::WebServiceWorkerClientCallbacks*) override;
95 void getClients(const blink::WebServiceWorkerClientQueryOptions&, 97 void getClients(const blink::WebServiceWorkerClientQueryOptions&,
96 blink::WebServiceWorkerClientsCallbacks*) override; 98 blink::WebServiceWorkerClientsCallbacks*) override;
97 void openWindow(const blink::WebURL&, 99 void openWindow(const blink::WebURL&,
98 blink::WebServiceWorkerClientCallbacks*) override; 100 blink::WebServiceWorkerClientCallbacks*) override;
99 void setCachedMetadata(const blink::WebURL&, 101 void setCachedMetadata(const blink::WebURL&,
100 const char* data, 102 const char* data,
101 size_t size) override; 103 size_t size) override;
102 void clearCachedMetadata(const blink::WebURL&) override; 104 void clearCachedMetadata(const blink::WebURL&) override;
103 void workerReadyForInspection() override; 105 void workerReadyForInspection() override;
104 106
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 void OnPostMessage( 222 void OnPostMessage(
221 const base::string16& message, 223 const base::string16& message,
222 const std::vector<TransferredMessagePort>& sent_message_ports, 224 const std::vector<TransferredMessagePort>& sent_message_ports,
223 const std::vector<int>& new_routing_ids); 225 const std::vector<int>& new_routing_ids);
224 226
225 void OnCrossOriginMessageToWorker( 227 void OnCrossOriginMessageToWorker(
226 const NavigatorConnectClient& client, 228 const NavigatorConnectClient& client,
227 const base::string16& message, 229 const base::string16& message,
228 const std::vector<TransferredMessagePort>& sent_message_ports, 230 const std::vector<TransferredMessagePort>& sent_message_ports,
229 const std::vector<int>& new_routing_ids); 231 const std::vector<int>& new_routing_ids);
232 void OnDidGetClient(int request_id, const ServiceWorkerClientInfo& client);
230 void OnDidGetClients( 233 void OnDidGetClients(
231 int request_id, const std::vector<ServiceWorkerClientInfo>& clients); 234 int request_id, const std::vector<ServiceWorkerClientInfo>& clients);
232 void OnOpenWindowResponse(int request_id, 235 void OnOpenWindowResponse(int request_id,
233 const ServiceWorkerClientInfo& client); 236 const ServiceWorkerClientInfo& client);
234 void OnOpenWindowError(int request_id, const std::string& message); 237 void OnOpenWindowError(int request_id, const std::string& message);
235 void OnFocusClientResponse(int request_id, 238 void OnFocusClientResponse(int request_id,
236 const ServiceWorkerClientInfo& client); 239 const ServiceWorkerClientInfo& client);
237 void OnNavigateClientResponse(int request_id, 240 void OnNavigateClientResponse(int request_id,
238 const ServiceWorkerClientInfo& client); 241 const ServiceWorkerClientInfo& client);
239 void OnNavigateClientError(int request_id, const GURL& url); 242 void OnNavigateClientError(int request_id, const GURL& url);
(...skipping 23 matching lines...) Expand all
263 // Initialized on the worker thread in workerContextStarted and 266 // Initialized on the worker thread in workerContextStarted and
264 // destructed on the worker thread in willDestroyWorkerContext. 267 // destructed on the worker thread in willDestroyWorkerContext.
265 scoped_ptr<WorkerContextData> context_; 268 scoped_ptr<WorkerContextData> context_;
266 269
267 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerContextClient); 270 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerContextClient);
268 }; 271 };
269 272
270 } // namespace content 273 } // namespace content
271 274
272 #endif // CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ 275 #endif // CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698