| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 SYNC_API_SYNC_DATA_H_ | 5 #ifndef SYNC_API_SYNC_DATA_H_ |
| 6 #define SYNC_API_SYNC_DATA_H_ | 6 #define SYNC_API_SYNC_DATA_H_ |
| 7 | 7 |
| 8 #include <iosfwd> | 8 #include <iosfwd> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 183 // | 183 // |
| 184 // |callback| will be invoked when the operation is complete (successfully | 184 // |callback| will be invoked when the operation is complete (successfully |
| 185 // or otherwise). | 185 // or otherwise). |
| 186 // | 186 // |
| 187 // Retrieving the requested attachments may require reading local storage or | 187 // Retrieving the requested attachments may require reading local storage or |
| 188 // requesting the attachments from the network. | 188 // requesting the attachments from the network. |
| 189 // | 189 // |
| 190 void GetOrDownloadAttachments( | 190 void GetOrDownloadAttachments( |
| 191 const AttachmentIdList& attachment_ids, | 191 const AttachmentIdList& attachment_ids, |
| 192 const AttachmentService::GetOrDownloadCallback& callback); | 192 const AttachmentService::GetOrDownloadCallback& callback); |
| 193 | |
| 194 // Drop (delete from local storage) the attachments associated with this | |
| 195 // SyncData specified in |attachment_ids|. This method will not delete | |
| 196 // attachments from the server. | |
| 197 // | |
| 198 // |callback| will be invoked when the operation is complete (successfully | |
| 199 // or otherwise). | |
| 200 void DropAttachments(const AttachmentIdList& attachment_ids, | |
| 201 const AttachmentService::DropCallback& callback); | |
| 202 }; | 193 }; |
| 203 | 194 |
| 204 // gmock printer helper. | 195 // gmock printer helper. |
| 205 void PrintTo(const SyncData& sync_data, std::ostream* os); | 196 void PrintTo(const SyncData& sync_data, std::ostream* os); |
| 206 | 197 |
| 207 typedef std::vector<SyncData> SyncDataList; | 198 typedef std::vector<SyncData> SyncDataList; |
| 208 | 199 |
| 209 } // namespace syncer | 200 } // namespace syncer |
| 210 | 201 |
| 211 #endif // SYNC_API_SYNC_DATA_H_ | 202 #endif // SYNC_API_SYNC_DATA_H_ |
| OLD | NEW |