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

Side by Side Diff: components/sync/api/mock_model_type_store.h

Issue 2388673002: Revert of [Sync] Move //components/sync to the syncer namespace. (patchset #5 id:40001 of https://co (Closed)
Patch Set: 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 #ifndef COMPONENTS_SYNC_API_MOCK_MODEL_TYPE_STORE_H_ 5 #ifndef COMPONENTS_SYNC_API_MOCK_MODEL_TYPE_STORE_H_
6 #define COMPONENTS_SYNC_API_MOCK_MODEL_TYPE_STORE_H_ 6 #define COMPONENTS_SYNC_API_MOCK_MODEL_TYPE_STORE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
11 #include "components/sync/api/model_type_store.h" 11 #include "components/sync/api/model_type_store.h"
12 12
13 namespace syncer { 13 namespace syncer_v2 {
14 14
15 // MockModelTypeStore is implementation of ModelTypeStore that does nothing. 15 // MockModelTypeStore is implementation of ModelTypeStore that does nothing.
16 // Use it when testing components that depend on ModelTypeStore. 16 // Use it when testing components that depend on ModelTypeStore.
17 // 17 //
18 // By default all methods return SUCCESS and empty results. It is possible to 18 // By default all methods return SUCCESS and empty results. It is possible to
19 // register custom handlers for certain functions to override behavior. It is 19 // register custom handlers for certain functions to override behavior. It is
20 // responsibility of handler to post callback with result. 20 // responsibility of handler to post callback with result.
21 // Here is an example: 21 // Here is an example:
22 // === 22 // ===
23 // void OnReadData(const ModelTypeStore::IdList& id_list, 23 // void OnReadData(const ModelTypeStore::IdList& id_list,
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 ReadAllMetadataSignature read_all_metadata_handler_; 105 ReadAllMetadataSignature read_all_metadata_handler_;
106 CommitWriteBatchSignature commit_write_batch_handler_; 106 CommitWriteBatchSignature commit_write_batch_handler_;
107 WriteRecordSignature write_data_handler_; 107 WriteRecordSignature write_data_handler_;
108 WriteRecordSignature write_metadata_handler_; 108 WriteRecordSignature write_metadata_handler_;
109 WriteGlobalMetadataSignature write_global_metadata_handler_; 109 WriteGlobalMetadataSignature write_global_metadata_handler_;
110 DeleteRecordSignature delete_data_handler_; 110 DeleteRecordSignature delete_data_handler_;
111 DeleteRecordSignature delete_metadata_handler_; 111 DeleteRecordSignature delete_metadata_handler_;
112 DeleteGlobalMetadataSignature delete_global_metadata_handler_; 112 DeleteGlobalMetadataSignature delete_global_metadata_handler_;
113 }; 113 };
114 114
115 } // namespace syncer 115 } // namespace syncer_v2
116 116
117 #endif // COMPONENTS_SYNC_API_MOCK_MODEL_TYPE_STORE_H_ 117 #endif // COMPONENTS_SYNC_API_MOCK_MODEL_TYPE_STORE_H_
OLDNEW
« no previous file with comments | « components/sync/api/metadata_change_list.h ('k') | components/sync/api/mock_model_type_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698