OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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_WEB_VIEW_PUBLIC_CWV_WEB_VIEW_CONFIGURATION_H_ | 5 #ifndef IOS_WEB_VIEW_PUBLIC_CWV_WEB_VIEW_CONFIGURATION_H_ |
6 #define IOS_WEB_VIEW_PUBLIC_CWV_WEB_VIEW_CONFIGURATION_H_ | 6 #define IOS_WEB_VIEW_PUBLIC_CWV_WEB_VIEW_CONFIGURATION_H_ |
7 | 7 |
8 #import <Foundation/Foundation.h> | 8 #import <Foundation/Foundation.h> |
9 | 9 |
| 10 // TODO(crbug.com/704946): Make framework style include work everywhere and |
| 11 // remove this #if. |
| 12 #if defined(CWV_IMPLEMENTATION) |
| 13 #include "ios/web_view/public/cwv_export.h" |
| 14 #else |
| 15 #include <ChromeWebView/cwv_export.h> |
| 16 #endif |
| 17 |
10 @class CWVUserContentController; | 18 @class CWVUserContentController; |
11 @class CWVWebsiteDataStore; | 19 @class CWVWebsiteDataStore; |
12 | 20 |
13 // Configuration used for creation of a CWVWebView. | 21 // Configuration used for creation of a CWVWebView. |
| 22 CWV_EXPORT |
14 @interface CWVWebViewConfiguration : NSObject<NSCopying> | 23 @interface CWVWebViewConfiguration : NSObject<NSCopying> |
15 | 24 |
16 // Configuration with persistent data store which stores all data on disk. | 25 // Configuration with persistent data store which stores all data on disk. |
17 + (instancetype)defaultConfiguration; | 26 + (instancetype)defaultConfiguration; |
18 | 27 |
19 // Configuration with ephemeral data store that neven stores data on disk. | 28 // Configuration with ephemeral data store that neven stores data on disk. |
20 + (instancetype)incognitoConfiguration; | 29 + (instancetype)incognitoConfiguration; |
21 | 30 |
22 - (instancetype)init NS_UNAVAILABLE; | 31 - (instancetype)init NS_UNAVAILABLE; |
23 | 32 |
24 // The user content controller to associate with web views created using this | 33 // The user content controller to associate with web views created using this |
25 // configuration. | 34 // configuration. |
26 @property(nonatomic, readonly) CWVUserContentController* userContentController; | 35 @property(nonatomic, readonly) CWVUserContentController* userContentController; |
27 | 36 |
28 // YES if it is a configuration with persistent data store which stores all data | 37 // YES if it is a configuration with persistent data store which stores all data |
29 // on disk. | 38 // on disk. |
30 @property(nonatomic, readonly, getter=isPersistent) BOOL persistent; | 39 @property(nonatomic, readonly, getter=isPersistent) BOOL persistent; |
31 | 40 |
32 @end | 41 @end |
33 | 42 |
34 #endif // IOS_WEB_VIEW_PUBLIC_CWV_WEB_VIEW_CONFIGURATION_H_ | 43 #endif // IOS_WEB_VIEW_PUBLIC_CWV_WEB_VIEW_CONFIGURATION_H_ |
OLD | NEW |