| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2004 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 |
| (...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 153 bool ready_for_remote_candidates() const { | 153 bool ready_for_remote_candidates() const { |
| 154 return local_description_set_ && remote_description_set_; | 154 return local_description_set_ && remote_description_set_; |
| 155 } | 155 } |
| 156 | 156 |
| 157 // Returns whether the client has requested the channels to connect. | 157 // Returns whether the client has requested the channels to connect. |
| 158 bool connect_requested() const { return connect_requested_; } | 158 bool connect_requested() const { return connect_requested_; } |
| 159 | 159 |
| 160 void SetIceRole(IceRole role); | 160 void SetIceRole(IceRole role); |
| 161 IceRole ice_role() const { return ice_role_; } | 161 IceRole ice_role() const { return ice_role_; } |
| 162 | 162 |
| 163 void SetIceTiebreaker(uint64 IceTiebreaker) { tiebreaker_ = IceTiebreaker; } | 163 void SetIceTiebreaker(uint64_t IceTiebreaker) { tiebreaker_ = IceTiebreaker; } |
| 164 uint64 IceTiebreaker() { return tiebreaker_; } | 164 uint64_t IceTiebreaker() { return tiebreaker_; } |
| 165 | 165 |
| 166 void SetIceConfig(const IceConfig& config); | 166 void SetIceConfig(const IceConfig& config); |
| 167 | 167 |
| 168 // Must be called before applying local session description. | 168 // Must be called before applying local session description. |
| 169 virtual void SetLocalCertificate( | 169 virtual void SetLocalCertificate( |
| 170 const rtc::scoped_refptr<rtc::RTCCertificate>& certificate) {} | 170 const rtc::scoped_refptr<rtc::RTCCertificate>& certificate) {} |
| 171 | 171 |
| 172 // Get a copy of the local certificate provided by SetLocalCertificate. | 172 // Get a copy of the local certificate provided by SetLocalCertificate. |
| 173 virtual bool GetLocalCertificate( | 173 virtual bool GetLocalCertificate( |
| 174 rtc::scoped_refptr<rtc::RTCCertificate>* certificate) { | 174 rtc::scoped_refptr<rtc::RTCCertificate>* certificate) { |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 283 | 283 |
| 284 // Helper function that invokes the given function on every channel. | 284 // Helper function that invokes the given function on every channel. |
| 285 typedef void (TransportChannelImpl::* TransportChannelFunc)(); | 285 typedef void (TransportChannelImpl::* TransportChannelFunc)(); |
| 286 void CallChannels(TransportChannelFunc func); | 286 void CallChannels(TransportChannelFunc func); |
| 287 | 287 |
| 288 const std::string name_; | 288 const std::string name_; |
| 289 PortAllocator* const allocator_; | 289 PortAllocator* const allocator_; |
| 290 bool channels_destroyed_ = false; | 290 bool channels_destroyed_ = false; |
| 291 bool connect_requested_ = false; | 291 bool connect_requested_ = false; |
| 292 IceRole ice_role_ = ICEROLE_UNKNOWN; | 292 IceRole ice_role_ = ICEROLE_UNKNOWN; |
| 293 uint64 tiebreaker_ = 0; | 293 uint64_t tiebreaker_ = 0; |
| 294 IceMode remote_ice_mode_ = ICEMODE_FULL; | 294 IceMode remote_ice_mode_ = ICEMODE_FULL; |
| 295 IceConfig ice_config_; | 295 IceConfig ice_config_; |
| 296 rtc::scoped_ptr<TransportDescription> local_description_; | 296 rtc::scoped_ptr<TransportDescription> local_description_; |
| 297 rtc::scoped_ptr<TransportDescription> remote_description_; | 297 rtc::scoped_ptr<TransportDescription> remote_description_; |
| 298 bool local_description_set_ = false; | 298 bool local_description_set_ = false; |
| 299 bool remote_description_set_ = false; | 299 bool remote_description_set_ = false; |
| 300 | 300 |
| 301 ChannelMap channels_; | 301 ChannelMap channels_; |
| 302 | 302 |
| 303 RTC_DISALLOW_COPY_AND_ASSIGN(Transport); | 303 RTC_DISALLOW_COPY_AND_ASSIGN(Transport); |
| 304 }; | 304 }; |
| 305 | 305 |
| 306 | 306 |
| 307 } // namespace cricket | 307 } // namespace cricket |
| 308 | 308 |
| 309 #endif // WEBRTC_P2P_BASE_TRANSPORT_H_ | 309 #endif // WEBRTC_P2P_BASE_TRANSPORT_H_ |
| OLD | NEW |