| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_FACTORY_IMPL_H__ | |
| 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_FACTORY_IMPL_H__ | |
| 7 #pragma once | |
| 8 | |
| 9 #include <string> | |
| 10 | |
| 11 #include "base/basictypes.h" | |
| 12 #include "base/compiler_specific.h" | |
| 13 #include "chrome/browser/sync/profile_sync_factory.h" | |
| 14 | |
| 15 class CommandLine; | |
| 16 class Profile; | |
| 17 | |
| 18 class ProfileSyncFactoryImpl : public ProfileSyncFactory { | |
| 19 public: | |
| 20 ProfileSyncFactoryImpl(Profile* profile, CommandLine* command_line); | |
| 21 virtual ~ProfileSyncFactoryImpl() {} | |
| 22 | |
| 23 // ProfileSyncFactory interface. | |
| 24 virtual ProfileSyncService* CreateProfileSyncService( | |
| 25 const std::string& cros_user) OVERRIDE; | |
| 26 | |
| 27 virtual void RegisterDataTypes(ProfileSyncService* pss) OVERRIDE; | |
| 28 | |
| 29 virtual browser_sync::DataTypeManager* CreateDataTypeManager( | |
| 30 browser_sync::SyncBackendHost* backend, | |
| 31 const browser_sync::DataTypeController::TypeMap* controllers) OVERRIDE; | |
| 32 | |
| 33 virtual browser_sync::GenericChangeProcessor* CreateGenericChangeProcessor( | |
| 34 ProfileSyncService* profile_sync_service, | |
| 35 browser_sync::UnrecoverableErrorHandler* error_handler, | |
| 36 const base::WeakPtr<SyncableService>& local_service) OVERRIDE; | |
| 37 | |
| 38 virtual browser_sync::SharedChangeProcessor* | |
| 39 CreateSharedChangeProcessor() OVERRIDE; | |
| 40 | |
| 41 virtual SyncComponents CreateAppSyncComponents( | |
| 42 ProfileSyncService* profile_sync_service, | |
| 43 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 44 | |
| 45 virtual base::WeakPtr<SyncableService> GetAutofillProfileSyncableService( | |
| 46 WebDataService* web_data_service) const OVERRIDE; | |
| 47 | |
| 48 virtual base::WeakPtr<SyncableService> GetAutocompleteSyncableService( | |
| 49 WebDataService* web_data_service) const OVERRIDE; | |
| 50 | |
| 51 virtual SyncComponents CreateBookmarkSyncComponents( | |
| 52 ProfileSyncService* profile_sync_service, | |
| 53 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 54 | |
| 55 virtual SyncComponents CreateExtensionOrAppSettingSyncComponents( | |
| 56 // Either EXTENSION_SETTING or APP_SETTING. | |
| 57 syncable::ModelType type, | |
| 58 SyncableService* settings_service, | |
| 59 ProfileSyncService* profile_sync_service, | |
| 60 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 61 | |
| 62 virtual SyncComponents CreateExtensionSyncComponents( | |
| 63 ProfileSyncService* profile_sync_service, | |
| 64 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 65 | |
| 66 virtual SyncComponents CreatePasswordSyncComponents( | |
| 67 ProfileSyncService* profile_sync_service, | |
| 68 PasswordStore* password_store, | |
| 69 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 70 | |
| 71 virtual SyncComponents CreatePreferenceSyncComponents( | |
| 72 ProfileSyncService* profile_sync_service, | |
| 73 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 74 | |
| 75 virtual SyncComponents CreateThemeSyncComponents( | |
| 76 ProfileSyncService* profile_sync_service, | |
| 77 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 78 | |
| 79 virtual SyncComponents CreateTypedUrlSyncComponents( | |
| 80 ProfileSyncService* profile_sync_service, | |
| 81 history::HistoryBackend* history_backend, | |
| 82 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 83 | |
| 84 virtual SyncComponents CreateSessionSyncComponents( | |
| 85 ProfileSyncService* profile_sync_service, | |
| 86 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 87 | |
| 88 virtual SyncComponents CreateSearchEngineSyncComponents( | |
| 89 ProfileSyncService* profile_sync_service, | |
| 90 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 91 | |
| 92 virtual SyncComponents CreateAppNotificationSyncComponents( | |
| 93 ProfileSyncService* profile_sync_service, | |
| 94 browser_sync::UnrecoverableErrorHandler* error_handler) OVERRIDE; | |
| 95 | |
| 96 private: | |
| 97 Profile* profile_; | |
| 98 CommandLine* command_line_; | |
| 99 | |
| 100 DISALLOW_COPY_AND_ASSIGN(ProfileSyncFactoryImpl); | |
| 101 }; | |
| 102 | |
| 103 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_FACTORY_IMPL_H__ | |
| OLD | NEW |