| 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_WEB_SERVICE_WORKER_PROVIDER_IMPL_H_ | 5 #ifndef CONTENT_CHILD_SERVICE_WORKER_WEB_SERVICE_WORKER_PROVIDER_IMPL_H_ |
| 6 #define CONTENT_CHILD_SERVICE_WORKER_WEB_SERVICE_WORKER_PROVIDER_IMPL_H_ | 6 #define CONTENT_CHILD_SERVICE_WORKER_WEB_SERVICE_WORKER_PROVIDER_IMPL_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 public: | 30 public: |
| 31 WebServiceWorkerProviderImpl(ThreadSafeSender* thread_safe_sender, | 31 WebServiceWorkerProviderImpl(ThreadSafeSender* thread_safe_sender, |
| 32 ServiceWorkerProviderContext* context); | 32 ServiceWorkerProviderContext* context); |
| 33 ~WebServiceWorkerProviderImpl() override; | 33 ~WebServiceWorkerProviderImpl() override; |
| 34 | 34 |
| 35 void SetClient(blink::WebServiceWorkerProviderClient* client) override; | 35 void SetClient(blink::WebServiceWorkerProviderClient* client) override; |
| 36 | 36 |
| 37 void RegisterServiceWorker( | 37 void RegisterServiceWorker( |
| 38 const blink::WebURL& pattern, | 38 const blink::WebURL& pattern, |
| 39 const blink::WebURL& script_url, | 39 const blink::WebURL& script_url, |
| 40 blink::WebServiceWorkerUpdateViaCache update_via_cache, |
| 40 std::unique_ptr<WebServiceWorkerRegistrationCallbacks>) override; | 41 std::unique_ptr<WebServiceWorkerRegistrationCallbacks>) override; |
| 41 void GetRegistration( | 42 void GetRegistration( |
| 42 const blink::WebURL& document_url, | 43 const blink::WebURL& document_url, |
| 43 std::unique_ptr<WebServiceWorkerGetRegistrationCallbacks>) override; | 44 std::unique_ptr<WebServiceWorkerGetRegistrationCallbacks>) override; |
| 44 void GetRegistrations( | 45 void GetRegistrations( |
| 45 std::unique_ptr<WebServiceWorkerGetRegistrationsCallbacks>) override; | 46 std::unique_ptr<WebServiceWorkerGetRegistrationsCallbacks>) override; |
| 46 void GetRegistrationForReady( | 47 void GetRegistrationForReady( |
| 47 std::unique_ptr<WebServiceWorkerGetRegistrationForReadyCallbacks>) | 48 std::unique_ptr<WebServiceWorkerGetRegistrationForReadyCallbacks>) |
| 48 override; | 49 override; |
| 49 bool ValidateScopeAndScriptURL(const blink::WebURL& pattern, | 50 bool ValidateScopeAndScriptURL(const blink::WebURL& pattern, |
| 50 const blink::WebURL& script_url, | 51 const blink::WebURL& script_url, |
| 51 blink::WebString* error_message) override; | 52 blink::WebString* error_message) override; |
| 52 | 53 |
| 53 int provider_id() const; | 54 int provider_id() const; |
| 54 | 55 |
| 55 private: | 56 private: |
| 56 void RemoveProviderClient(); | 57 void RemoveProviderClient(); |
| 57 ServiceWorkerDispatcher* GetDispatcher(); | 58 ServiceWorkerDispatcher* GetDispatcher(); |
| 58 | 59 |
| 59 scoped_refptr<ThreadSafeSender> thread_safe_sender_; | 60 scoped_refptr<ThreadSafeSender> thread_safe_sender_; |
| 60 scoped_refptr<ServiceWorkerProviderContext> context_; | 61 scoped_refptr<ServiceWorkerProviderContext> context_; |
| 61 | 62 |
| 62 DISALLOW_COPY_AND_ASSIGN(WebServiceWorkerProviderImpl); | 63 DISALLOW_COPY_AND_ASSIGN(WebServiceWorkerProviderImpl); |
| 63 }; | 64 }; |
| 64 | 65 |
| 65 } // namespace content | 66 } // namespace content |
| 66 | 67 |
| 67 #endif // CONTENT_CHILD_SERVICE_WORKER_WEB_SERVICE_WORKER_PROVIDER_IMPL_H_ | 68 #endif // CONTENT_CHILD_SERVICE_WORKER_WEB_SERVICE_WORKER_PROVIDER_IMPL_H_ |
| OLD | NEW |