| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef REMOTING_CLIENT_IOS_HOST_PREFERENCES_H_ | |
| 6 #define REMOTING_CLIENT_IOS_HOST_PREFERENCES_H_ | |
| 7 | |
| 8 #import <CoreData/CoreData.h> | |
| 9 | |
| 10 // A HostPreferences contains details to negotiate and maintain a connection | |
| 11 // to a remote Chromoting host. This is an entity in a backing store. | |
| 12 @interface HostPreferences : NSObject<NSCoding> | |
| 13 | |
| 14 // Properties supplied by the host server. | |
| 15 @property(nonatomic, copy) NSString* hostId; | |
| 16 @property(nonatomic, copy) NSString* pairId; | |
| 17 @property(nonatomic, copy) NSString* pairSecret; | |
| 18 | |
| 19 // Commit this record using the Keychain for current identity. | |
| 20 - (void)saveToKeychain; | |
| 21 | |
| 22 // Load a record from the Keychain for current identity. | |
| 23 // If a record does not exist, return a new record with a blank secret. | |
| 24 + (HostPreferences*)hostForId:(NSString*)hostId; | |
| 25 | |
| 26 @end | |
| 27 | |
| 28 #endif // REMOTING_CLIENT_IOS_HOST_PREFERENCES_H_ | |
| OLD | NEW |