OLD | NEW |
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 CHROME_BROWSER_SYNC_GLUE_GENERIC_CHANGE_PROCESSOR_H_ | 5 #ifndef CHROME_BROWSER_SYNC_GLUE_GENERIC_CHANGE_PROCESSOR_H_ |
6 #define CHROME_BROWSER_SYNC_GLUE_GENERIC_CHANGE_PROCESSOR_H_ | 6 #define CHROME_BROWSER_SYNC_GLUE_GENERIC_CHANGE_PROCESSOR_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 int64 version, | 59 int64 version, |
60 const syncer::ImmutableChangeRecordList& changes) OVERRIDE; | 60 const syncer::ImmutableChangeRecordList& changes) OVERRIDE; |
61 // Passes |syncer_changes_|, built in ApplyChangesFromSyncModel, onto | 61 // Passes |syncer_changes_|, built in ApplyChangesFromSyncModel, onto |
62 // |local_service_| by way of its ProcessSyncChanges method. | 62 // |local_service_| by way of its ProcessSyncChanges method. |
63 virtual void CommitChangesFromSyncModel() OVERRIDE; | 63 virtual void CommitChangesFromSyncModel() OVERRIDE; |
64 | 64 |
65 // syncer::SyncChangeProcessor implementation. | 65 // syncer::SyncChangeProcessor implementation. |
66 virtual syncer::SyncError ProcessSyncChanges( | 66 virtual syncer::SyncError ProcessSyncChanges( |
67 const tracked_objects::Location& from_here, | 67 const tracked_objects::Location& from_here, |
68 const syncer::SyncChangeList& change_list) OVERRIDE; | 68 const syncer::SyncChangeList& change_list) OVERRIDE; |
69 | |
70 // Fills a list of SyncData. This should create an up to date representation | |
71 // of all the data known to the ChangeProcessor for |datatype|, and | |
72 // should match/be a subset of the server's view of that datatype. | |
73 virtual syncer::SyncDataList GetAllSyncData(syncer::ModelType type) | 69 virtual syncer::SyncDataList GetAllSyncData(syncer::ModelType type) |
74 const OVERRIDE; | 70 const OVERRIDE; |
| 71 virtual syncer::SyncError UpdateDataTypeContext( |
| 72 syncer::ModelType type, |
| 73 const std::string& context) OVERRIDE; |
75 | 74 |
76 // Similar to above, but returns a SyncError for use by direct clients | 75 // Similar to above, but returns a SyncError for use by direct clients |
77 // of GenericChangeProcessor that may need more error visibility. | 76 // of GenericChangeProcessor that may need more error visibility. |
78 virtual syncer::SyncError GetAllSyncDataReturnError( | 77 virtual syncer::SyncError GetAllSyncDataReturnError( |
79 syncer::ModelType type, | 78 syncer::ModelType type, |
80 syncer::SyncDataList* data) const; | 79 syncer::SyncDataList* data) const; |
81 | 80 |
82 // Returns the number of items for this type. | 81 // Returns the number of items for this type. |
83 virtual int GetSyncCountForType(syncer::ModelType type); | 82 virtual int GetSyncCountForType(syncer::ModelType type); |
84 | 83 |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 base::WeakPtrFactory<syncer::AttachmentService> | 134 base::WeakPtrFactory<syncer::AttachmentService> |
136 attachment_service_weak_ptr_factory_; | 135 attachment_service_weak_ptr_factory_; |
137 syncer::AttachmentServiceProxy attachment_service_proxy_; | 136 syncer::AttachmentServiceProxy attachment_service_proxy_; |
138 | 137 |
139 DISALLOW_COPY_AND_ASSIGN(GenericChangeProcessor); | 138 DISALLOW_COPY_AND_ASSIGN(GenericChangeProcessor); |
140 }; | 139 }; |
141 | 140 |
142 } // namespace browser_sync | 141 } // namespace browser_sync |
143 | 142 |
144 #endif // CHROME_BROWSER_SYNC_GLUE_GENERIC_CHANGE_PROCESSOR_H_ | 143 #endif // CHROME_BROWSER_SYNC_GLUE_GENERIC_CHANGE_PROCESSOR_H_ |
OLD | NEW |