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

Side by Side Diff: components/sync/api/stub_model_type_service.cc

Issue 2376123003: [Sync] Move //components/sync to the syncer namespace. (Closed)
Patch Set: Rebase. Created 4 years, 2 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/api/stub_model_type_service.h" 5 #include "components/sync/api/stub_model_type_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "components/sync/api/fake_model_type_change_processor.h" 9 #include "components/sync/api/fake_model_type_change_processor.h"
10 10
11 namespace syncer_v2 { 11 namespace syncer {
12 12
13 StubModelTypeService::StubModelTypeService() 13 StubModelTypeService::StubModelTypeService()
14 : StubModelTypeService(base::Bind(&FakeModelTypeChangeProcessor::Create)) {} 14 : StubModelTypeService(base::Bind(&FakeModelTypeChangeProcessor::Create)) {}
15 15
16 StubModelTypeService::StubModelTypeService( 16 StubModelTypeService::StubModelTypeService(
17 const ChangeProcessorFactory& change_processor_factory) 17 const ChangeProcessorFactory& change_processor_factory)
18 : ModelTypeService(change_processor_factory, syncer::PREFERENCES) {} 18 : ModelTypeService(change_processor_factory, PREFERENCES) {}
19 19
20 StubModelTypeService::~StubModelTypeService() {} 20 StubModelTypeService::~StubModelTypeService() {}
21 21
22 std::unique_ptr<MetadataChangeList> 22 std::unique_ptr<MetadataChangeList>
23 StubModelTypeService::CreateMetadataChangeList() { 23 StubModelTypeService::CreateMetadataChangeList() {
24 return std::unique_ptr<MetadataChangeList>(); 24 return std::unique_ptr<MetadataChangeList>();
25 } 25 }
26 26
27 syncer::SyncError StubModelTypeService::MergeSyncData( 27 SyncError StubModelTypeService::MergeSyncData(
28 std::unique_ptr<MetadataChangeList> metadata_change_list, 28 std::unique_ptr<MetadataChangeList> metadata_change_list,
29 EntityDataMap entity_data_map) { 29 EntityDataMap entity_data_map) {
30 return syncer::SyncError(); 30 return SyncError();
31 } 31 }
32 32
33 syncer::SyncError StubModelTypeService::ApplySyncChanges( 33 SyncError StubModelTypeService::ApplySyncChanges(
34 std::unique_ptr<MetadataChangeList> metadata_change_list, 34 std::unique_ptr<MetadataChangeList> metadata_change_list,
35 EntityChangeList entity_changes) { 35 EntityChangeList entity_changes) {
36 return syncer::SyncError(); 36 return SyncError();
37 } 37 }
38 38
39 void StubModelTypeService::GetData(StorageKeyList storage_keys, 39 void StubModelTypeService::GetData(StorageKeyList storage_keys,
40 DataCallback callback) {} 40 DataCallback callback) {}
41 41
42 void StubModelTypeService::GetAllData(DataCallback callback) {} 42 void StubModelTypeService::GetAllData(DataCallback callback) {}
43 43
44 std::string StubModelTypeService::GetClientTag(const EntityData& entity_data) { 44 std::string StubModelTypeService::GetClientTag(const EntityData& entity_data) {
45 return std::string(); 45 return std::string();
46 } 46 }
47 47
48 std::string StubModelTypeService::GetStorageKey(const EntityData& entity_data) { 48 std::string StubModelTypeService::GetStorageKey(const EntityData& entity_data) {
49 return std::string(); 49 return std::string();
50 } 50 }
51 51
52 void StubModelTypeService::OnChangeProcessorSet() {} 52 void StubModelTypeService::OnChangeProcessorSet() {}
53 53
54 bool StubModelTypeService::HasChangeProcessor() const { 54 bool StubModelTypeService::HasChangeProcessor() const {
55 return change_processor() != nullptr; 55 return change_processor() != nullptr;
56 } 56 }
57 57
58 } // namespace syncer_v2 58 } // namespace syncer
OLDNEW
« no previous file with comments | « components/sync/api/stub_model_type_service.h ('k') | components/sync/api/sync_change_processor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698