| 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 262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 273 std::string* local_username, | 273 std::string* local_username, |
| 274 std::string* remote_username) const; | 274 std::string* remote_username) const; |
| 275 void CreateStunUsername(const std::string& remote_username, | 275 void CreateStunUsername(const std::string& remote_username, |
| 276 std::string* stun_username_attr_str) const; | 276 std::string* stun_username_attr_str) const; |
| 277 | 277 |
| 278 bool MaybeIceRoleConflict(const rtc::SocketAddress& addr, | 278 bool MaybeIceRoleConflict(const rtc::SocketAddress& addr, |
| 279 IceMessage* stun_msg, | 279 IceMessage* stun_msg, |
| 280 const std::string& remote_ufrag); | 280 const std::string& remote_ufrag); |
| 281 | 281 |
| 282 // Called when a packet has been sent to the socket. | 282 // Called when a packet has been sent to the socket. |
| 283 void OnSentPacket(const rtc::SentPacket& sent_packet); | 283 // This is made pure virtual to notify subclasses of Port that they MUST |
| 284 // listen to AsyncPacketSocket::SignalSentPacket and then call |
| 285 // PortInterface::OnSentPacket. |
| 286 virtual void OnSentPacket(rtc::AsyncPacketSocket* socket, |
| 287 const rtc::SentPacket& sent_packet) = 0; |
| 284 | 288 |
| 285 // Called when the socket is currently able to send. | 289 // Called when the socket is currently able to send. |
| 286 void OnReadyToSend(); | 290 void OnReadyToSend(); |
| 287 | 291 |
| 288 // Called when the Connection discovers a local peer reflexive candidate. | 292 // Called when the Connection discovers a local peer reflexive candidate. |
| 289 // Returns the index of the new local candidate. | 293 // Returns the index of the new local candidate. |
| 290 size_t AddPrflxCandidate(const Candidate& local); | 294 size_t AddPrflxCandidate(const Candidate& local); |
| 291 | 295 |
| 292 void set_candidate_filter(uint32_t candidate_filter) { | 296 void set_candidate_filter(uint32_t candidate_filter) { |
| 293 candidate_filter_ = candidate_filter; | 297 candidate_filter_ = candidate_filter; |
| (...skipping 355 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 649 const rtc::PacketOptions& options) override; | 653 const rtc::PacketOptions& options) override; |
| 650 int GetError() override { return error_; } | 654 int GetError() override { return error_; } |
| 651 | 655 |
| 652 private: | 656 private: |
| 653 int error_ = 0; | 657 int error_ = 0; |
| 654 }; | 658 }; |
| 655 | 659 |
| 656 } // namespace cricket | 660 } // namespace cricket |
| 657 | 661 |
| 658 #endif // WEBRTC_P2P_BASE_PORT_H_ | 662 #endif // WEBRTC_P2P_BASE_PORT_H_ |
| OLD | NEW |