Jonas Oreland | 09c452e | 2019-11-20 08:01:02 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2019 The WebRTC Project Authors. All rights reserved. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style license |
| 5 | * that can be found in the LICENSE file in the root of the source |
| 6 | * tree. An additional intellectual property rights grant can be found |
| 7 | * in the file PATENTS. All contributing project authors may |
| 8 | * be found in the AUTHORS file in the root of the source tree. |
| 9 | */ |
| 10 | |
| 11 | #include "p2p/base/ice_controller_interface.h" |
| 12 | |
| 13 | #include <string> |
| 14 | |
Sameer Vijaykar | 3382c1c | 2022-06-02 09:29:09 | [diff] [blame] | 15 | #include "p2p/base/ice_switch_reason.h" |
| 16 | |
Jonas Oreland | 09c452e | 2019-11-20 08:01:02 | [diff] [blame] | 17 | namespace cricket { |
| 18 | |
Sameer Vijaykar | 2a1accd | 2022-06-03 09:39:39 | [diff] [blame] | 19 | std::string IceRecheckEvent::ToString() const { |
Sameer Vijaykar | 3382c1c | 2022-06-02 09:29:09 | [diff] [blame] | 20 | std::string str = IceSwitchReasonToString(reason); |
Sameer Vijaykar | 9453e5f | 2022-05-31 11:38:20 | [diff] [blame] | 21 | if (recheck_delay_ms) { |
Sameer Vijaykar | 3382c1c | 2022-06-02 09:29:09 | [diff] [blame] | 22 | str += " (after delay: " + std::to_string(recheck_delay_ms) + ")"; |
Sameer Vijaykar | 9453e5f | 2022-05-31 11:38:20 | [diff] [blame] | 23 | } |
Sameer Vijaykar | 3382c1c | 2022-06-02 09:29:09 | [diff] [blame] | 24 | return str; |
| 25 | } |
| 26 | |
Jonas Oreland | 09c452e | 2019-11-20 08:01:02 | [diff] [blame] | 27 | } // namespace cricket |