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

Side by Side Diff: components/reading_list/ios/reading_list_model.h

Issue 2745313004: Remove all ReadingList entries on managed account signout. (Closed)
Patch Set: feedback Created 3 years, 9 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 COMPONENTS_READING_LIST_IOS_READING_LIST_MODEL_H_ 5 #ifndef COMPONENTS_READING_LIST_IOS_READING_LIST_MODEL_H_
6 #define COMPONENTS_READING_LIST_IOS_READING_LIST_MODEL_H_ 6 #define COMPONENTS_READING_LIST_IOS_READING_LIST_MODEL_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 // Returns the total number of unread entries in the model. 62 // Returns the total number of unread entries in the model.
63 virtual size_t unread_size() const = 0; 63 virtual size_t unread_size() const = 0;
64 64
65 // Returns the total number of unseen entries in the model. Note: These 65 // Returns the total number of unseen entries in the model. Note: These
66 // entries are also unread so unseen_size() <= unread_size(). 66 // entries are also unread so unseen_size() <= unread_size().
67 virtual size_t unseen_size() const = 0; 67 virtual size_t unseen_size() const = 0;
68 68
69 // Mark all unseen entries as unread. 69 // Mark all unseen entries as unread.
70 virtual void MarkAllSeen() = 0; 70 virtual void MarkAllSeen() = 0;
71 71
72 // Delete all the Reading List entries. Return true if entries where indeed
73 // deleted.
74 virtual bool DeleteAllEntries() = 0;
75
72 // Returns the flag about unseen entries on the device. 76 // Returns the flag about unseen entries on the device.
73 // This flag is raised if some unseen items are added on this device. 77 // This flag is raised if some unseen items are added on this device.
74 // The flag is reset if |ResetLocalUnseenFlag| is called or if all unseen 78 // The flag is reset if |ResetLocalUnseenFlag| is called or if all unseen
75 // entries are removed. 79 // entries are removed.
76 // This is a local flag and it can have different values on different devices, 80 // This is a local flag and it can have different values on different devices,
77 // even if they are synced. 81 // even if they are synced.
78 // (unseen_size() == 0 => GetLocalUnseenFlag() == false) 82 // (unseen_size() == 0 => GetLocalUnseenFlag() == false)
79 virtual bool GetLocalUnseenFlag() const = 0; 83 virtual bool GetLocalUnseenFlag() const = 0;
80 84
81 // Set the unseen flag to false. 85 // Set the unseen flag to false.
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 // Called when model is leaving batch update mode. 166 // Called when model is leaving batch update mode.
163 virtual void LeavingBatchUpdates(); 167 virtual void LeavingBatchUpdates();
164 168
165 private: 169 private:
166 unsigned int current_batch_updates_count_; 170 unsigned int current_batch_updates_count_;
167 171
168 DISALLOW_COPY_AND_ASSIGN(ReadingListModel); 172 DISALLOW_COPY_AND_ASSIGN(ReadingListModel);
169 }; 173 };
170 174
171 #endif // COMPONENTS_READING_LIST_IOS_READING_LIST_MODEL_H_ 175 #endif // COMPONENTS_READING_LIST_IOS_READING_LIST_MODEL_H_
OLDNEW
« no previous file with comments | « components/reading_list/ios/favicon_web_state_dispatcher.h ('k') | components/reading_list/ios/reading_list_model_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698