OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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_SESSIONS_TEST_SESSION_SERVICE_H_ | 5 #ifndef IOS_CHROME_BROWSER_SESSIONS_TEST_SESSION_SERVICE_H_ |
6 #define IOS_CHROME_BROWSER_SESSIONS_TEST_SESSION_SERVICE_H_ | 6 #define IOS_CHROME_BROWSER_SESSIONS_TEST_SESSION_SERVICE_H_ |
7 | 7 |
8 #import <Foundation/Foundation.h> | 8 #import <Foundation/Foundation.h> |
9 | 9 |
10 #import "ios/chrome/browser/sessions/session_service_ios.h" | 10 #import "ios/chrome/browser/sessions/session_service_ios.h" |
11 | 11 |
12 // Testing subclass of SessionService that immediately consumes and archives | 12 // Testing subclass of SessionService that immediately consumes session windows |
13 // to nowhere session windows passed into its | 13 // passed to -saveSessionWindow:sessionPath:immediately: is consumed immediately |
14 // -saveWindow:forBrowserState:immediately: method. | 14 // but only saved to disk if |performIO| is set to YES.. |
15 @interface TestSessionService : SessionServiceIOS | 15 @interface TestSessionService : SessionServiceIOS |
| 16 |
| 17 // If YES, then sessions are saved to disk, otherwise, data is discarded. |
| 18 @property(nonatomic, assign) BOOL performIO; |
| 19 |
16 @end | 20 @end |
17 | 21 |
18 #endif // IOS_CHROME_BROWSER_SESSIONS_TEST_SESSION_SERVICE_H_ | 22 #endif // IOS_CHROME_BROWSER_SESSIONS_TEST_SESSION_SERVICE_H_ |
OLD | NEW |