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 COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_ | 5 #ifndef COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_ |
6 #define COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_ | 6 #define COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
255 | 255 |
256 // Tell the sync manager to persist its state by writing to disk. | 256 // Tell the sync manager to persist its state by writing to disk. |
257 // Called on the sync thread, both by a timer and, on Android, when the | 257 // Called on the sync thread, both by a timer and, on Android, when the |
258 // application is backgrounded. | 258 // application is backgrounded. |
259 void SaveChanges(); | 259 void SaveChanges(); |
260 | 260 |
261 void DoClearServerData( | 261 void DoClearServerData( |
262 const syncer::SyncManager::ClearServerDataCallback& frontend_callback); | 262 const syncer::SyncManager::ClearServerDataCallback& frontend_callback); |
263 | 263 |
264 // Notify the syncer that the cookie jar has changed. | 264 // Notify the syncer that the cookie jar has changed. |
265 void DoOnCookieJarChanged(bool account_mismatch); | 265 void DoOnCookieJarChanged(bool account_mismatch, bool empty_jar); |
266 | 266 |
267 private: | 267 private: |
268 friend class base::RefCountedThreadSafe<SyncBackendHostCore>; | 268 friend class base::RefCountedThreadSafe<SyncBackendHostCore>; |
269 friend class SyncBackendHostForProfileSyncTest; | 269 friend class SyncBackendHostForProfileSyncTest; |
270 | 270 |
271 ~SyncBackendHostCore() override; | 271 ~SyncBackendHostCore() override; |
272 | 272 |
273 // Invoked when initialization of syncapi is complete and we can start | 273 // Invoked when initialization of syncapi is complete and we can start |
274 // our timer. | 274 // our timer. |
275 // This must be called from the thread on which SaveChanges is intended to | 275 // This must be called from the thread on which SaveChanges is intended to |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
335 std::map<syncer::ModelType, int64_t> last_invalidation_versions_; | 335 std::map<syncer::ModelType, int64_t> last_invalidation_versions_; |
336 | 336 |
337 base::WeakPtrFactory<SyncBackendHostCore> weak_ptr_factory_; | 337 base::WeakPtrFactory<SyncBackendHostCore> weak_ptr_factory_; |
338 | 338 |
339 DISALLOW_COPY_AND_ASSIGN(SyncBackendHostCore); | 339 DISALLOW_COPY_AND_ASSIGN(SyncBackendHostCore); |
340 }; | 340 }; |
341 | 341 |
342 } // namespace browser_sync | 342 } // namespace browser_sync |
343 | 343 |
344 #endif // COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_ | 344 #endif // COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_CORE_H_ |
OLD | NEW |