OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_BACKGROUND_SYNC_BACKGROUND_SYNC_MANAGER_H_ | 5 #ifndef CONTENT_BROWSER_BACKGROUND_SYNC_BACKGROUND_SYNC_MANAGER_H_ |
6 #define CONTENT_BROWSER_BACKGROUND_SYNC_BACKGROUND_SYNC_MANAGER_H_ | 6 #define CONTENT_BROWSER_BACKGROUND_SYNC_BACKGROUND_SYNC_MANAGER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 int64 sw_registration_id, | 114 int64 sw_registration_id, |
115 const GURL& origin, | 115 const GURL& origin, |
116 const std::string& backend_key, | 116 const std::string& backend_key, |
117 const std::string& data, | 117 const std::string& data, |
118 const ServiceWorkerStorage::StatusCallback& callback); | 118 const ServiceWorkerStorage::StatusCallback& callback); |
119 virtual void GetDataFromBackend( | 119 virtual void GetDataFromBackend( |
120 const std::string& backend_key, | 120 const std::string& backend_key, |
121 const ServiceWorkerStorage::GetUserDataForAllRegistrationsCallback& | 121 const ServiceWorkerStorage::GetUserDataForAllRegistrationsCallback& |
122 callback); | 122 callback); |
123 virtual void FireOneShotSync( | 123 virtual void FireOneShotSync( |
| 124 const BackgroundSyncRegistration& registration, |
124 const scoped_refptr<ServiceWorkerVersion>& active_version, | 125 const scoped_refptr<ServiceWorkerVersion>& active_version, |
125 const ServiceWorkerVersion::StatusCallback& callback); | 126 const ServiceWorkerVersion::StatusCallback& callback); |
126 | 127 |
127 private: | 128 private: |
128 class RegistrationKey { | 129 class RegistrationKey { |
129 public: | 130 public: |
130 explicit RegistrationKey(const BackgroundSyncRegistration& registration); | 131 explicit RegistrationKey(const BackgroundSyncRegistration& registration); |
131 explicit RegistrationKey(const BackgroundSyncRegistrationOptions& options); | 132 explicit RegistrationKey(const BackgroundSyncRegistrationOptions& options); |
132 RegistrationKey(const std::string& tag, SyncPeriodicity periodicity); | 133 RegistrationKey(const std::string& tag, SyncPeriodicity periodicity); |
133 RegistrationKey(const RegistrationKey& other) = default; | 134 RegistrationKey(const RegistrationKey& other) = default; |
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
301 scoped_ptr<BackgroundSyncPowerObserver> power_observer_; | 302 scoped_ptr<BackgroundSyncPowerObserver> power_observer_; |
302 | 303 |
303 base::WeakPtrFactory<BackgroundSyncManager> weak_ptr_factory_; | 304 base::WeakPtrFactory<BackgroundSyncManager> weak_ptr_factory_; |
304 | 305 |
305 DISALLOW_COPY_AND_ASSIGN(BackgroundSyncManager); | 306 DISALLOW_COPY_AND_ASSIGN(BackgroundSyncManager); |
306 }; | 307 }; |
307 | 308 |
308 } // namespace content | 309 } // namespace content |
309 | 310 |
310 #endif // CONTENT_BROWSER_BACKGROUND_SYNC_BACKGROUND_SYNC_MANAGER_H_ | 311 #endif // CONTENT_BROWSER_BACKGROUND_SYNC_BACKGROUND_SYNC_MANAGER_H_ |
OLD | NEW |