Index: sync/api/sync_data.h |
diff --git a/sync/api/sync_data.h b/sync/api/sync_data.h |
index 717b1e1175d5b5f9e0bbc797928118fb9b0388ad..a8d69dd3aea81d164e84ce50f0776c8b0f4656a7 100644 |
--- a/sync/api/sync_data.h |
+++ b/sync/api/sync_data.h |
@@ -11,6 +11,7 @@ |
#include "base/basictypes.h" |
#include "base/callback.h" |
+#include "base/memory/ref_counted.h" |
#include "base/stl_util.h" |
#include "base/time/time.h" |
#include "sync/api/attachments/attachment.h" |
@@ -64,18 +65,12 @@ class SYNC_EXPORT SyncData { |
const AttachmentList& attachments); |
// Helper method for creating SyncData objects originating from the syncer. |
- // |
- // TODO(maniscalco): Replace all calls to 3-arg CreateRemoteData with calls to |
- // the 5-arg version (bug 353296). |
static SyncData CreateRemoteData( |
int64 id, |
const sync_pb::EntitySpecifics& specifics, |
const base::Time& last_modified_time, |
const AttachmentIdList& attachment_ids, |
- const syncer::AttachmentServiceProxy& attachment_service); |
- static SyncData CreateRemoteData(int64 id, |
- const sync_pb::EntitySpecifics& specifics, |
- const base::Time& last_modified_time); |
+ const scoped_refptr<syncer::AttachmentServiceProxy>& attachment_service); |
// Whether this SyncData holds valid data. The only way to have a SyncData |
// without valid data is to use the default constructor. |
@@ -138,18 +133,19 @@ class SYNC_EXPORT SyncData { |
Immutable<AttachmentList> attachments_; |
- AttachmentServiceProxy attachment_service_; |
+ scoped_refptr<AttachmentServiceProxy> attachment_service_; |
private: |
// Whether this SyncData holds valid data. |
bool is_valid_; |
// Clears |entity| and |attachments|. |
- SyncData(int64 id, |
- sync_pb::SyncEntity* entity, |
- AttachmentList* attachments, |
- const base::Time& remote_modification_time, |
- const syncer::AttachmentServiceProxy& attachment_service); |
+ SyncData( |
+ int64 id, |
+ sync_pb::SyncEntity* entity, |
+ AttachmentList* attachments, |
+ const base::Time& remote_modification_time, |
+ const scoped_refptr<syncer::AttachmentServiceProxy>& attachment_service); |
}; |
// A SyncData going to the syncer. |