OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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_UI_COMMANDS_SET_UP_FOR_TESTING_COMMAND_H_ | 5 #ifndef IOS_CHROME_BROWSER_UI_COMMANDS_SET_UP_FOR_TESTING_COMMAND_H_ |
6 #define IOS_CHROME_BROWSER_UI_COMMANDS_SET_UP_FOR_TESTING_COMMAND_H_ | 6 #define IOS_CHROME_BROWSER_UI_COMMANDS_SET_UP_FOR_TESTING_COMMAND_H_ |
7 | 7 |
8 #import <Foundation/Foundation.h> | 8 #import <Foundation/Foundation.h> |
9 | 9 |
| 10 #import "ios/chrome/browser/ui/commands/generic_chrome_command.h" |
| 11 |
10 class GURL; | 12 class GURL; |
11 | 13 |
12 // Set up for testing command that can be passed to |chromeExecuteCommand|. | 14 // Set up for testing command that can be passed to |chromeExecuteCommand|. |
13 @interface SetUpForTestingCommand : NSObject | 15 @interface SetUpForTestingCommand : GenericChromeCommand |
| 16 |
| 17 // Mark inherited initializer as unavailable to prevent calling it by mistake. |
| 18 - (instancetype)initWithTag:(NSInteger)tag NS_UNAVAILABLE; |
14 | 19 |
15 // Initializes this command by parsing the url query. | 20 // Initializes this command by parsing the url query. |
16 - (instancetype)initWithURL:(const GURL&)url; | 21 - (instancetype)initWithURL:(const GURL&)url; |
17 | 22 |
18 // Initializes this command. | 23 // Initializes this command. |
19 - (instancetype)initWithClearBrowsingData:(BOOL)clearBrowsingData | 24 - (instancetype)initWithClearBrowsingData:(BOOL)clearBrowsingData |
20 closeTabs:(BOOL)closeTabs | 25 closeTabs:(BOOL)closeTabs |
21 numberOfNewTabs:(NSInteger)numberOfNewTabs; | 26 numberOfNewTabs:(NSInteger)numberOfNewTabs |
| 27 NS_DESIGNATED_INITIALIZER; |
22 | 28 |
23 @property(nonatomic, readonly, assign) BOOL clearBrowsingData; | 29 // Whether the browsing data should be cleared. |
24 @property(nonatomic, readonly, assign) BOOL closeTabs; | 30 @property(nonatomic, readonly) BOOL clearBrowsingData; |
25 @property(nonatomic, assign) NSInteger numberOfNewTabs; | 31 |
| 32 // Whether the existing tabs should be closed. |
| 33 @property(nonatomic, readonly) BOOL closeTabs; |
| 34 |
| 35 // The number of new tabs to create. |
| 36 @property(nonatomic, readonly) NSInteger numberOfNewTabs; |
26 | 37 |
27 @end | 38 @end |
28 | 39 |
29 #endif // IOS_CHROME_BROWSER_UI_COMMANDS_SET_UP_FOR_TESTING_COMMAND_H_ | 40 #endif // IOS_CHROME_BROWSER_UI_COMMANDS_SET_UP_FOR_TESTING_COMMAND_H_ |
OLD | NEW |