OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2016 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2016 The WebRTC Project Authors. All rights reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 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 | 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 | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 #ifndef WEBRTC_P2P_BASE_ICETRANSPORTINTERNAL_H_ | 11 #ifndef WEBRTC_P2P_BASE_ICETRANSPORTINTERNAL_H_ |
12 #define WEBRTC_P2P_BASE_ICETRANSPORTINTERNAL_H_ | 12 #define WEBRTC_P2P_BASE_ICETRANSPORTINTERNAL_H_ |
13 | 13 |
14 #include <string> | 14 #include <string> |
15 | 15 |
16 #include "webrtc/p2p/base/candidate.h" | 16 #include "webrtc/p2p/base/candidate.h" |
17 #include "webrtc/p2p/base/candidatepairinterface.h" | 17 #include "webrtc/p2p/base/candidatepairinterface.h" |
18 #include "webrtc/p2p/base/jseptransport.h" | 18 #include "webrtc/p2p/base/jseptransport.h" |
19 #include "webrtc/p2p/base/packettransportinterface.h" | 19 #include "webrtc/p2p/base/packettransportinterface.h" |
20 #include "webrtc/p2p/base/transportdescription.h" | 20 #include "webrtc/p2p/base/transportdescription.h" |
21 | 21 |
22 namespace webrtc { | 22 namespace webrtc { |
23 class MetricsObserverInterface; | 23 class MetricsObserverInterface; |
24 } | 24 } |
25 | 25 |
26 namespace cricket { | 26 namespace cricket { |
27 | 27 |
28 class IceTransportInternal; | 28 // TODO(zhihuang): replace it with PeerConnectionInterface::IceConnectionState. |
29 typedef IceTransportInternal IceTransportInternal2; | |
30 | |
31 // TODO(zhihuang): Replace this with | |
32 // PeerConnectionInterface::IceConnectionState. | |
33 enum class IceTransportState { | 29 enum class IceTransportState { |
34 STATE_INIT, | 30 STATE_INIT, |
35 STATE_CONNECTING, // Will enter this state once a connection is created | 31 STATE_CONNECTING, // Will enter this state once a connection is created |
36 STATE_COMPLETED, | 32 STATE_COMPLETED, |
37 STATE_FAILED | 33 STATE_FAILED |
38 }; | 34 }; |
39 | 35 |
40 // TODO(zhihuang): Remove this once it's no longer used in | 36 // TODO(zhihuang): Remove this once it's no longer used in |
41 // remoting/protocol/libjingle_transport_factory.cc | 37 // remoting/protocol/libjingle_transport_factory.cc |
42 enum IceProtocolType { | 38 enum IceProtocolType { |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 // agents. | 127 // agents. |
132 sigslot::signal1<IceTransportInternal*> SignalRoleConflict; | 128 sigslot::signal1<IceTransportInternal*> SignalRoleConflict; |
133 | 129 |
134 // Emitted whenever the transport state changed. | 130 // Emitted whenever the transport state changed. |
135 sigslot::signal1<IceTransportInternal*> SignalStateChanged; | 131 sigslot::signal1<IceTransportInternal*> SignalStateChanged; |
136 | 132 |
137 // Invoked when the transport is being destroyed. | 133 // Invoked when the transport is being destroyed. |
138 sigslot::signal1<IceTransportInternal*> SignalDestroyed; | 134 sigslot::signal1<IceTransportInternal*> SignalDestroyed; |
139 | 135 |
140 // Debugging description of this transport. | 136 // Debugging description of this transport. |
141 std::string debug_name() const override { | 137 const std::string debug_name() const override { |
142 return transport_name() + " " + std::to_string(component()); | 138 return transport_name() + " " + std::to_string(component()); |
143 } | 139 } |
144 }; | 140 }; |
145 | 141 |
146 } // namespace cricket | 142 } // namespace cricket |
147 | 143 |
148 #endif // WEBRTC_P2P_BASE_ICETRANSPORTINTERNAL_H_ | 144 #endif // WEBRTC_P2P_BASE_ICETRANSPORTINTERNAL_H_ |
OLD | NEW |