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

Side by Side Diff: components/sync/driver/glue/sync_backend_host_mock.cc

Issue 2473613003: [Sync] Adds a new switch for enabling the new local server backend. (Closed)
Patch Set: Ifdef protect the variable. Created 4 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 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 #include "components/sync/driver/glue/sync_backend_host_mock.h" 5 #include "components/sync/driver/glue/sync_backend_host_mock.h"
6 6
7 #include "components/sync/driver/sync_frontend.h" 7 #include "components/sync/driver/sync_frontend.h"
8 #include "components/sync/engine/activation_context.h" 8 #include "components/sync/engine/activation_context.h"
9 9
10 namespace syncer { 10 namespace syncer {
11 11
12 const char kTestCacheGuid[] = "test-guid"; 12 const char kTestCacheGuid[] = "test-guid";
13 13
14 SyncBackendHostMock::SyncBackendHostMock() : fail_initial_download_(false) {} 14 SyncBackendHostMock::SyncBackendHostMock() : fail_initial_download_(false) {}
15 SyncBackendHostMock::~SyncBackendHostMock() {} 15 SyncBackendHostMock::~SyncBackendHostMock() {}
16 16
17 void SyncBackendHostMock::Initialize( 17 void SyncBackendHostMock::Initialize(
18 SyncFrontend* frontend, 18 SyncFrontend* frontend,
19 std::unique_ptr<base::Thread> sync_thread, 19 std::unique_ptr<base::Thread> sync_thread,
20 const scoped_refptr<base::SingleThreadTaskRunner>& db_thread, 20 const scoped_refptr<base::SingleThreadTaskRunner>& db_thread,
21 const scoped_refptr<base::SingleThreadTaskRunner>& file_thread, 21 const scoped_refptr<base::SingleThreadTaskRunner>& file_thread,
22 const WeakHandle<JsEventHandler>& event_handler, 22 const WeakHandle<JsEventHandler>& event_handler,
23 const GURL& service_url, 23 const GURL& service_url,
24 const std::string& sync_user_agent, 24 const std::string& sync_user_agent,
25 const SyncCredentials& credentials, 25 const SyncCredentials& credentials,
26 bool delete_sync_data_folder, 26 bool delete_sync_data_folder,
27 bool enable_local_sync_backend,
28 const base::FilePath& local_sync_backend_folder,
27 std::unique_ptr<SyncManagerFactory> sync_manager_factory, 29 std::unique_ptr<SyncManagerFactory> sync_manager_factory,
28 const WeakHandle<UnrecoverableErrorHandler>& unrecoverable_error_handler, 30 const WeakHandle<UnrecoverableErrorHandler>& unrecoverable_error_handler,
29 const base::Closure& report_unrecoverable_error_function, 31 const base::Closure& report_unrecoverable_error_function,
30 const HttpPostProviderFactoryGetter& http_post_provider_factory_getter, 32 const HttpPostProviderFactoryGetter& http_post_provider_factory_getter,
31 std::unique_ptr<SyncEncryptionHandler::NigoriState> saved_nigori_state) { 33 std::unique_ptr<SyncEncryptionHandler::NigoriState> saved_nigori_state) {
32 frontend->OnBackendInitialized(WeakHandle<JsBackend>(), 34 frontend->OnBackendInitialized(WeakHandle<JsBackend>(),
33 WeakHandle<DataTypeDebugInfoListener>(), 35 WeakHandle<DataTypeDebugInfoListener>(),
34 kTestCacheGuid, !fail_initial_download_); 36 kTestCacheGuid, !fail_initial_download_);
35 } 37 }
36 38
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 140
139 void SyncBackendHostMock::ClearServerData( 141 void SyncBackendHostMock::ClearServerData(
140 const SyncManager::ClearServerDataCallback& callback) { 142 const SyncManager::ClearServerDataCallback& callback) {
141 callback.Run(); 143 callback.Run();
142 } 144 }
143 145
144 void SyncBackendHostMock::OnCookieJarChanged(bool account_mismatch, 146 void SyncBackendHostMock::OnCookieJarChanged(bool account_mismatch,
145 bool empty_jar) {} 147 bool empty_jar) {}
146 148
147 } // namespace syncer 149 } // namespace syncer
OLDNEW
« no previous file with comments | « components/sync/driver/glue/sync_backend_host_mock.h ('k') | components/sync/engine/sync_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698