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

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

Issue 1421003007: [Sync] Componentize ProfileSyncComponentsFactoryImpl (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix sessions api test Created 5 years, 1 month 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_BROWSER_PROFILE_SYNC_SERVICE_H_ 5 #ifndef COMPONENTS_BROWSER_SYNC_BROWSER_PROFILE_SYNC_SERVICE_H_
6 #define COMPONENTS_BROWSER_SYNC_BROWSER_PROFILE_SYNC_SERVICE_H_ 6 #define COMPONENTS_BROWSER_SYNC_BROWSER_PROFILE_SYNC_SERVICE_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 UNKNOWN_ERROR, 223 UNKNOWN_ERROR,
224 }; 224 };
225 225
226 enum BackendMode { 226 enum BackendMode {
227 IDLE, // No backend. 227 IDLE, // No backend.
228 SYNC, // Backend for syncing. 228 SYNC, // Backend for syncing.
229 BACKUP, // Backend for backup. 229 BACKUP, // Backend for backup.
230 ROLLBACK // Backend for rollback. 230 ROLLBACK // Backend for rollback.
231 }; 231 };
232 232
233 // Takes ownership of |factory| and |signin_wrapper|.
234 ProfileSyncService( 233 ProfileSyncService(
235 scoped_ptr<sync_driver::SyncClient> sync_client, 234 scoped_ptr<sync_driver::SyncClient> sync_client,
236 scoped_ptr<SigninManagerWrapper> signin_wrapper, 235 scoped_ptr<SigninManagerWrapper> signin_wrapper,
237 ProfileOAuth2TokenService* oauth2_token_service, 236 ProfileOAuth2TokenService* oauth2_token_service,
238 browser_sync::ProfileSyncServiceStartBehavior start_behavior, 237 browser_sync::ProfileSyncServiceStartBehavior start_behavior,
239 const syncer::NetworkTimeUpdateCallback& network_time_update_callback, 238 const syncer::NetworkTimeUpdateCallback& network_time_update_callback,
240 base::FilePath base_directory, 239 base::FilePath base_directory,
241 scoped_refptr<net::URLRequestContextGetter> url_request_context, 240 scoped_refptr<net::URLRequestContextGetter> url_request_context,
242 std::string debug_identifier, 241 std::string debug_identifier,
243 version_info::Channel channel, 242 version_info::Channel channel,
(...skipping 697 matching lines...) Expand 10 before | Expand all | Expand 10 after
941 base::Time next_token_request_time_; 940 base::Time next_token_request_time_;
942 941
943 scoped_ptr<sync_driver::LocalDeviceInfoProvider> local_device_; 942 scoped_ptr<sync_driver::LocalDeviceInfoProvider> local_device_;
944 943
945 // Locally owned SyncableService implementations. 944 // Locally owned SyncableService implementations.
946 scoped_ptr<browser_sync::SessionsSyncManager> sessions_sync_manager_; 945 scoped_ptr<browser_sync::SessionsSyncManager> sessions_sync_manager_;
947 scoped_ptr<sync_driver::DeviceInfoSyncService> device_info_sync_service_; 946 scoped_ptr<sync_driver::DeviceInfoSyncService> device_info_sync_service_;
948 947
949 scoped_ptr<syncer::NetworkResources> network_resources_; 948 scoped_ptr<syncer::NetworkResources> network_resources_;
950 949
950 browser_sync::ProfileSyncServiceStartBehavior start_behavior_;
951 scoped_ptr<browser_sync::StartupController> startup_controller_; 951 scoped_ptr<browser_sync::StartupController> startup_controller_;
952 952
953 scoped_ptr<sync_driver::BackupRollbackController> backup_rollback_controller_; 953 scoped_ptr<sync_driver::BackupRollbackController> backup_rollback_controller_;
954 954
955 // Mode of current backend. 955 // Mode of current backend.
956 BackendMode backend_mode_; 956 BackendMode backend_mode_;
957 957
958 // Whether backup is needed before sync starts. 958 // Whether backup is needed before sync starts.
959 bool need_backup_; 959 bool need_backup_;
960 960
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
1007 base::WeakPtrFactory<ProfileSyncService> startup_controller_weak_factory_; 1007 base::WeakPtrFactory<ProfileSyncService> startup_controller_weak_factory_;
1008 1008
1009 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); 1009 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService);
1010 }; 1010 };
1011 1011
1012 bool ShouldShowActionOnUI( 1012 bool ShouldShowActionOnUI(
1013 const syncer::SyncProtocolError& error); 1013 const syncer::SyncProtocolError& error);
1014 1014
1015 1015
1016 #endif // COMPONENTS_BROWSER_SYNC_BROWSER_PROFILE_SYNC_SERVICE_H_ 1016 #endif // COMPONENTS_BROWSER_SYNC_BROWSER_PROFILE_SYNC_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698