| 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_FACADE_HOST_INFO_H_ | |
| 6 #define REMOTING_CLIENT_IOS_FACADE_HOST_INFO_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 #include <vector> | |
| 10 | |
| 11 #include "base/values.h" | |
| 12 | |
| 13 namespace remoting { | |
| 14 | |
| 15 enum HostStatus { kHostStatusOnline, kHostStatusOffline }; | |
| 16 | |
| 17 // |remoting::HostInfo| is an object containing the data from host list fetch | |
| 18 // for transport in native code. | |
| 19 struct HostInfo { | |
| 20 HostInfo(); | |
| 21 HostInfo(const HostInfo& other); | |
| 22 ~HostInfo(); | |
| 23 | |
| 24 // Returns true if |host_info| is valid and initializes HostInfo. | |
| 25 bool ParseHostInfo(const base::DictionaryValue& host_info); | |
| 26 | |
| 27 // Returns true if the chromoting host is ready to accept connections. | |
| 28 bool IsReadyForConnection() const; | |
| 29 | |
| 30 std::string host_id; | |
| 31 std::string host_jid; | |
| 32 std::string host_name; | |
| 33 HostStatus status = kHostStatusOffline; | |
| 34 std::string offline_reason; | |
| 35 std::string public_key; | |
| 36 std::vector<std::string> token_url_patterns; | |
| 37 }; | |
| 38 | |
| 39 } // namespace remoting | |
| 40 | |
| 41 #endif // REMOTING_CLIENT_IOS_FACADE_HOST_INFO_H_ | |
| OLD | NEW |