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

Side by Side Diff: components/browser_sync/profile_sync_service.h

Issue 2863173002: [Sync] Switch ModelTypeStore* from blocking pool to post_task.h (Closed)
Patch Set: Self review. Created 3 years, 7 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 5 #ifndef COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
6 #define COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 6 #define COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after
552 // Returns a serialized NigoriKey proto generated from the bootstrap token in 552 // Returns a serialized NigoriKey proto generated from the bootstrap token in
553 // SyncPrefs. Will return the empty string if no bootstrap token exists. 553 // SyncPrefs. Will return the empty string if no bootstrap token exists.
554 std::string GetCustomPassphraseKey() const; 554 std::string GetCustomPassphraseKey() const;
555 555
556 // Set the provider for whether sync is currently allowed by the platform. 556 // Set the provider for whether sync is currently allowed by the platform.
557 void SetPlatformSyncAllowedProvider( 557 void SetPlatformSyncAllowedProvider(
558 const PlatformSyncAllowedProvider& platform_sync_allowed_provider); 558 const PlatformSyncAllowedProvider& platform_sync_allowed_provider);
559 559
560 // Returns a function for |type| that will create a ModelTypeStore that shares 560 // Returns a function for |type| that will create a ModelTypeStore that shares
561 // the sync LevelDB backend. |base_path| should be set to profile path. 561 // the sync LevelDB backend. |base_path| should be set to profile path.
562 // |sequenced_worker_pool| is obtained from content::BrowserThread or
563 // web::WebThread depending on platform.
564 static syncer::ModelTypeStoreFactory GetModelTypeStoreFactory( 562 static syncer::ModelTypeStoreFactory GetModelTypeStoreFactory(
565 syncer::ModelType type, 563 syncer::ModelType type,
566 const base::FilePath& base_path, 564 const base::FilePath& base_path);
567 base::SequencedWorkerPool* sequenced_worker_pool);
568 565
569 // Needed to test whether the directory is deleted properly. 566 // Needed to test whether the directory is deleted properly.
570 base::FilePath GetDirectoryPathForTest() const; 567 base::FilePath GetDirectoryPathForTest() const;
571 568
572 // Sometimes we need to wait for tasks on the sync thread in tests. 569 // Sometimes we need to wait for tasks on the sync thread in tests.
573 base::MessageLoop* GetSyncLoopForTest() const; 570 base::MessageLoop* GetSyncLoopForTest() const;
574 571
575 // Some tests rely on injecting calls to the encryption observer. 572 // Some tests rely on injecting calls to the encryption observer.
576 syncer::SyncEncryptionHandler::Observer* GetEncryptionObserverForTest() const; 573 syncer::SyncEncryptionHandler::Observer* GetEncryptionObserverForTest() const;
577 574
(...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after
899 base::WeakPtrFactory<ProfileSyncService> weak_factory_; 896 base::WeakPtrFactory<ProfileSyncService> weak_factory_;
900 897
901 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); 898 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService);
902 }; 899 };
903 900
904 bool ShouldShowActionOnUI(const syncer::SyncProtocolError& error); 901 bool ShouldShowActionOnUI(const syncer::SyncProtocolError& error);
905 902
906 } // namespace browser_sync 903 } // namespace browser_sync
907 904
908 #endif // COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ 905 #endif // COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/printing/printers_manager_factory.cc ('k') | components/browser_sync/profile_sync_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698