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

Unified Diff: ios/chrome/browser/ui/commands/clear_browsing_data_command.h

Issue 2270063005: Add support for time based deletion of browsing data on iOS (Closed)
Patch Set: Updated comment in AccountConsistencyService Created 4 years, 3 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/ui/commands/clear_browsing_data_command.h
diff --git a/ios/chrome/browser/ui/commands/clear_browsing_data_command.h b/ios/chrome/browser/ui/commands/clear_browsing_data_command.h
index cd9100f7594785243f3bf5869d0816adf0b9e69e..09d0a65c2b96701e1250267a447b361d8da9aed4 100644
--- a/ios/chrome/browser/ui/commands/clear_browsing_data_command.h
+++ b/ios/chrome/browser/ui/commands/clear_browsing_data_command.h
@@ -7,6 +7,7 @@
#import <Foundation/Foundation.h>
+#import "components/browsing_data/core/browsing_data_utils.h"
#import "ios/chrome/browser/ui/commands/generic_chrome_command.h"
namespace ios {
@@ -20,9 +21,16 @@ class ChromeBrowserState;
- (instancetype)initWithTag:(NSInteger)tag NS_UNAVAILABLE;
// Initializes a command intented to clear browsing data for |browserState|
-// that correspong to removal mask |mask|.
+// that corresponds to removal mask |mask| for the time period |timePeriod|.
- (instancetype)initWithBrowserState:(ios::ChromeBrowserState*)browserState
- mask:(int)mask NS_DESIGNATED_INITIALIZER;
+ mask:(int)mask
+ timePeriod:(browsing_data::TimePeriod)timePeriod
+ NS_DESIGNATED_INITIALIZER;
+
+// DEPRECATED: Same as above, but setting |timePeriod| to ALL_TIME.
+// TODO(ioanap): Remove after all call sites are changed.
+- (instancetype)initWithBrowserState:(ios::ChromeBrowserState*)browserState
+ mask:(int)mask;
// When executed this command will remove browsing data for this BrowserState.
@property(nonatomic, readonly) ios::ChromeBrowserState* browserState;
@@ -30,6 +38,9 @@ class ChromeBrowserState;
// Removal mask: see BrowsingDataRemover::RemoveDataMask.
@property(nonatomic, readonly) int mask;
+// Time period for which the browsing data will be removed.
+@property(nonatomic, readonly) browsing_data::TimePeriod timePeriod;
+
@end
#endif // IOS_CHROME_BROWSER_UI_COMMANDS_CLEAR_BROWSING_DATA_COMMAND_H_
« no previous file with comments | « ios/chrome/browser/signin/browser_state_data_remover.mm ('k') | ios/chrome/browser/ui/commands/clear_browsing_data_command.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698