Commit 4cc7bad9 authored by olivierrobin's avatar olivierrobin Committed by Commit bot

Add destructor to ReadingListStoreDelegate

ReadingListStoreDelegate has virtual methods, so it should have a virtual
destructor.

BUG=673169

Review-Url: https://codereview.chromium.org/2565213002
Cr-Commit-Position: refs/heads/master@{#437801}
parent 39493e82
...@@ -7,13 +7,20 @@ ...@@ -7,13 +7,20 @@
#include <map> #include <map>
#include "base/macros.h"
class ReadingListEntry; class ReadingListEntry;
// The delegate to handle callbacks from the ReadingListStore. // The delegate to handle callbacks from the ReadingListStore.
class ReadingListStoreDelegate { class ReadingListStoreDelegate {
public: public:
ReadingListStoreDelegate() {}
virtual ~ReadingListStoreDelegate() {}
using ReadingListEntries = std::map<GURL, ReadingListEntry>; using ReadingListEntries = std::map<GURL, ReadingListEntry>;
// These three mathods handle callbacks from a ReadingListStore. // These three methods handle callbacks from a ReadingListStore.
// This method is called when the local store is loaded. |entries| contains
// the ReadingListEntry present on the device before sync starts.
virtual void StoreLoaded(std::unique_ptr<ReadingListEntries> entries) = 0; virtual void StoreLoaded(std::unique_ptr<ReadingListEntries> entries) = 0;
// Handle sync events. // Handle sync events.
// Called to add a new entry to the model. // Called to add a new entry to the model.
...@@ -29,6 +36,8 @@ class ReadingListStoreDelegate { ...@@ -29,6 +36,8 @@ class ReadingListStoreDelegate {
// Called to remove an entry to the model. // Called to remove an entry to the model.
virtual void SyncRemoveEntry(const GURL& url) = 0; virtual void SyncRemoveEntry(const GURL& url) = 0;
private:
DISALLOW_COPY_AND_ASSIGN(ReadingListStoreDelegate);
}; };
#endif // COMPONENTS_READING_LIST_IOS_READING_LIST_STORE_DELEGATE_H_ #endif // COMPONENTS_READING_LIST_IOS_READING_LIST_STORE_DELEGATE_H_
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment