Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: ios/chrome/browser/reading_list/reading_list_model_impl.h

Issue 2362063004: Find reading list entry state in model from url (Closed)
Patch Set: Addressing comments + tests Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 IOS_CHROME_BROWSER_READING_LIST_READING_LIST_MODEL_IMPL_H_ 5 #ifndef IOS_CHROME_BROWSER_READING_LIST_READING_LIST_MODEL_IMPL_H_
6 #define IOS_CHROME_BROWSER_READING_LIST_READING_LIST_MODEL_IMPL_H_ 6 #define IOS_CHROME_BROWSER_READING_LIST_READING_LIST_MODEL_IMPL_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "components/keyed_service/core/keyed_service.h" 10 #include "components/keyed_service/core/keyed_service.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 const GURL& url, 43 const GURL& url,
44 base::Callback<void(const ReadingListEntry&)> callback) const override; 44 base::Callback<void(const ReadingListEntry&)> callback) const override;
45 45
46 void RemoveEntryByUrl(const GURL& url) override; 46 void RemoveEntryByUrl(const GURL& url) override;
47 47
48 const ReadingListEntry& AddEntry(const GURL& url, 48 const ReadingListEntry& AddEntry(const GURL& url,
49 const std::string& title) override; 49 const std::string& title) override;
50 50
51 void MarkReadByURL(const GURL& url) override; 51 void MarkReadByURL(const GURL& url) override;
52 52
53 EntryState EntryStateByURL(const GURL& url) override;
54
53 void SetEntryTitle(const GURL& url, const std::string& title) override; 55 void SetEntryTitle(const GURL& url, const std::string& title) override;
54 void SetEntryDistilledURL(const GURL& url, 56 void SetEntryDistilledURL(const GURL& url,
55 const GURL& distilled_url) override; 57 const GURL& distilled_url) override;
56 void SetEntryDistilledState( 58 void SetEntryDistilledState(
57 const GURL& url, 59 const GURL& url,
58 ReadingListEntry::DistillationState state) override; 60 ReadingListEntry::DistillationState state) override;
59 61
60 protected: 62 protected:
61 void EndBatchUpdates() override; 63 void EndBatchUpdates() override;
62 64
63 private: 65 private:
64 typedef std::vector<ReadingListEntry> ReadingListEntries; 66 typedef std::vector<ReadingListEntry> ReadingListEntries;
65 67
66 ReadingListEntries unread_; 68 ReadingListEntries unread_;
67 ReadingListEntries read_; 69 ReadingListEntries read_;
68 std::unique_ptr<ReadingListModelStorage> storageLayer_; 70 std::unique_ptr<ReadingListModelStorage> storageLayer_;
69 bool hasUnseen_; 71 bool hasUnseen_;
70 bool loaded_; 72 bool loaded_;
71 73
72 DISALLOW_COPY_AND_ASSIGN(ReadingListModelImpl); 74 DISALLOW_COPY_AND_ASSIGN(ReadingListModelImpl);
73 }; 75 };
74 76
75 #endif // IOS_CHROME_BROWSER_READING_LIST_READING_LIST_MODEL_MEMORY_H_ 77 #endif // IOS_CHROME_BROWSER_READING_LIST_READING_LIST_MODEL_MEMORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698