OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef IOS_SHOWCASE_CORE_SHOWCASE_VIEW_CONTROLLER_H_ |
| 6 #define IOS_SHOWCASE_CORE_SHOWCASE_VIEW_CONTROLLER_H_ |
| 7 |
| 8 #import <UIKit/UIKit.h> |
| 9 |
| 10 namespace showcase { |
| 11 |
| 12 // Required name for class that is intended to be tested. |
| 13 extern NSString* const kClassForDisplayKey; |
| 14 |
| 15 // Required name for class that will be instantiated. |
| 16 extern NSString* const kClassForInstantiationKey; |
| 17 |
| 18 // Optional description of the use case for the row. |
| 19 extern NSString* const kUseCaseKey; |
| 20 |
| 21 // Type for one row of model. |
| 22 typedef NSDictionary<NSString*, NSString*> ModelRow; |
| 23 |
| 24 } // namespace showcase |
| 25 |
| 26 // TableViewController that displays a searchable list of rows. |
| 27 @interface ShowcaseViewController : UITableViewController |
| 28 // Initializes the tableView with a list of rows. |
| 29 - (instancetype)initWithRows:(NSArray<showcase::ModelRow*>*)rows |
| 30 NS_DESIGNATED_INITIALIZER; |
| 31 |
| 32 - (instancetype)init NS_UNAVAILABLE; |
| 33 - (instancetype)initWithCoder:(NSCoder*)aDecoder NS_UNAVAILABLE; |
| 34 - (instancetype)initWithNibName:(NSString*)nibNameOrNil |
| 35 bundle:(NSBundle*)nibBundleOrNil NS_UNAVAILABLE; |
| 36 - (instancetype)initWithStyle:(UITableViewStyle)style NS_UNAVAILABLE; |
| 37 @end |
| 38 |
| 39 #endif // IOS_SHOWCASE_CORE_SHOWCASE_VIEW_CONTROLLER_H_ |
OLD | NEW |