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_ |