Index: sync/api/attachments/attachment_store.h |
diff --git a/sync/api/attachments/attachment_store.h b/sync/api/attachments/attachment_store.h |
index 45ccaf9c8efa355eaa53862eaf89463fc86c97eb..d487f8cd1775673a6cc3cee53b788e9f730f6c35 100644 |
--- a/sync/api/attachments/attachment_store.h |
+++ b/sync/api/attachments/attachment_store.h |
@@ -25,8 +25,10 @@ |
// |
// Destroying this object does not necessarily cancel outstanding async |
// operations. If you need cancel like semantics, use WeakPtr in the callbacks. |
-class SYNC_EXPORT AttachmentStoreBase { |
+class SYNC_EXPORT AttachmentStore : public base::RefCounted<AttachmentStore> { |
public: |
+ AttachmentStore(); |
+ |
// TODO(maniscalco): Consider udpating Read and Write methods to support |
// resumable transfers (bug 353292). |
@@ -40,9 +42,6 @@ |
scoped_ptr<AttachmentIdList>)> ReadCallback; |
typedef base::Callback<void(const Result&)> WriteCallback; |
typedef base::Callback<void(const Result&)> DropCallback; |
- |
- AttachmentStoreBase(); |
- virtual ~AttachmentStoreBase(); |
// Asynchronously reads the attachments identified by |ids|. |
// |
@@ -82,22 +81,9 @@ |
// successfully. |
virtual void Drop(const AttachmentIdList& ids, |
const DropCallback& callback) = 0; |
-}; |
- |
-// AttachmentStore is an interface exposed to data type and AttachmentService |
-// code. Also contains factory methods for default implementations. |
-class SYNC_EXPORT AttachmentStore |
- : public AttachmentStoreBase, |
- public base::RefCountedThreadSafe<AttachmentStore> { |
- public: |
- AttachmentStore(); |
- |
- // Creates an AttachmentStoreHandle backed by in-memory implementation of |
- // attachment store. For now frontend lives on the same thread as backend. |
- static scoped_refptr<AttachmentStore> CreateInMemoryStore(); |
protected: |
- friend class base::RefCountedThreadSafe<AttachmentStore>; |
+ friend class base::RefCounted<AttachmentStore>; |
virtual ~AttachmentStore(); |
}; |