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

Unified Diff: ios/chrome/browser/browsing_data/browsing_data_remover_helper.h

Issue 2270063005: Add support for time based deletion of browsing data on iOS (Closed)
Patch Set: Added partial removal for cache Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: ios/chrome/browser/browsing_data/browsing_data_remover_helper.h
diff --git a/ios/chrome/browser/browsing_data/browsing_data_remover_helper.h b/ios/chrome/browser/browsing_data/browsing_data_remover_helper.h
index a5b73e9d4162fae5f815ba011452a0d5f01cbef7..d2ae1c1878932382d84eb100eb62810ebe7cb83c 100644
--- a/ios/chrome/browser/browsing_data/browsing_data_remover_helper.h
+++ b/ios/chrome/browser/browsing_data/browsing_data_remover_helper.h
@@ -32,6 +32,16 @@ class BrowsingDataRemoverHelper
// they are received in.
void Remove(ios::ChromeBrowserState* browser_state,
int remove_mask,
+ browsing_data::TimePeriod time_period,
+ const base::Closure& callback);
+ // Removes the specified browsing data associated with |browser_state|. Calls
+ // |callback| when the browsing data is actually removed. |browser_state|
+ // cannot be null and must not be off the record.
+ // |callback| is called on the main thread.
+ // Note: Removal operations are not necessarily processed in the sequence that
+ // they are received in.
+ void Remove(ios::ChromeBrowserState* browser_state,
msramek 2016/08/29 14:20:59 I would recommend not copy-pasting the comment, ju
ioanap 2016/08/30 11:32:08 Done.
+ int remove_mask,
const base::Closure& callback);
private:
@@ -39,11 +49,15 @@ class BrowsingDataRemoverHelper
// a ChromeBrowserState.
struct BrowsingDataRemovalInfo {
// Creates a BrowsingDataRemovalInfo with a single callback |callback|.
- BrowsingDataRemovalInfo(int remove_mask, const base::Closure& callback);
+ BrowsingDataRemovalInfo(int remove_mask,
+ browsing_data::TimePeriod time_period,
+ const base::Closure& callback);
~BrowsingDataRemovalInfo();
// The mask of all the types of browsing data that needs to be removed.
// Obtained from BrowsingDataRemoved::RemoveDataMask.
int remove_mask;
+ // Time period for which the user wants to remove the data.
+ browsing_data::TimePeriod time_period;
// The vector of callbacks that need to be run when browsing data is
// actually removed.
std::vector<base::Closure> callbacks;

Powered by Google App Engine
This is Rietveld 408576698