Avi Drissman | d6cdf9b | 2022-09-15 19:52:53 | [diff] [blame] | 1 | // Copyright 2014 The Chromium Authors |
[email protected] | b580f42 | 2014-05-22 22:21:23 | [diff] [blame] | 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_HOST_SERVER_LOG_ENTRY_HOST_H_ |
| 6 | #define REMOTING_HOST_SERVER_LOG_ENTRY_HOST_H_ |
| 7 | |
[email protected] | b580f42 | 2014-05-22 22:21:23 | [diff] [blame] | 8 | #include "remoting/protocol/transport.h" |
| 9 | |
| 10 | namespace remoting { |
| 11 | |
| 12 | class ServerLogEntry; |
| 13 | |
| 14 | // Constructs a log entry for a session state change. |
| 15 | // Currently this is either connection or disconnection. |
dcheng | 0765c49 | 2016-04-06 22:41:53 | [diff] [blame] | 16 | std::unique_ptr<ServerLogEntry> MakeLogEntryForSessionStateChange( |
[email protected] | b580f42 | 2014-05-22 22:21:23 | [diff] [blame] | 17 | bool connected); |
| 18 | |
[email protected] | b580f42 | 2014-05-22 22:21:23 | [diff] [blame] | 19 | // Adds fields describing the host to this log entry. |
| 20 | void AddHostFieldsToLogEntry(ServerLogEntry* entry); |
| 21 | |
| 22 | // Adds a field describing connection type (direct/stun/relay). |
| 23 | void AddConnectionTypeToLogEntry(ServerLogEntry* entry, |
| 24 | protocol::TransportRoute::RouteType type); |
| 25 | |
| 26 | } // namespace remoting |
| 27 | |
| 28 | #endif // REMOTING_HOST_SERVER_LOG_ENTRY_HOST_H_ |