| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 | 46 |
| 47 SendSideCongestionController::SendSideCongestionController( | 47 SendSideCongestionController::SendSideCongestionController( |
| 48 const Clock* clock, | 48 const Clock* clock, |
| 49 Observer* observer, | 49 Observer* observer, |
| 50 RtcEventLog* event_log, | 50 RtcEventLog* event_log, |
| 51 PacketRouter* packet_router) | 51 PacketRouter* packet_router) |
| 52 : SendSideCongestionController( | 52 : SendSideCongestionController( |
| 53 clock, | 53 clock, |
| 54 observer, | 54 observer, |
| 55 event_log, | 55 event_log, |
| 56 std::unique_ptr<PacedSender>( | 56 std::unique_ptr<PacedSender>(new PacedSender(clock, packet_router))) { |
| 57 new PacedSender(clock, packet_router, event_log))) {} | 57 } |
| 58 | 58 |
| 59 SendSideCongestionController::SendSideCongestionController( | 59 SendSideCongestionController::SendSideCongestionController( |
| 60 const Clock* clock, | 60 const Clock* clock, |
| 61 Observer* observer, | 61 Observer* observer, |
| 62 RtcEventLog* event_log, | 62 RtcEventLog* event_log, |
| 63 std::unique_ptr<PacedSender> pacer) | 63 std::unique_ptr<PacedSender> pacer) |
| 64 : clock_(clock), | 64 : clock_(clock), |
| 65 observer_(observer), | 65 observer_(observer), |
| 66 event_log_(event_log), | 66 event_log_(event_log), |
| 67 pacer_(std::move(pacer)), | 67 pacer_(std::move(pacer)), |
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 296 bool SendSideCongestionController::IsSendQueueFull() const { | 296 bool SendSideCongestionController::IsSendQueueFull() const { |
| 297 return pacer_->ExpectedQueueTimeMs() > PacedSender::kMaxQueueLengthMs; | 297 return pacer_->ExpectedQueueTimeMs() > PacedSender::kMaxQueueLengthMs; |
| 298 } | 298 } |
| 299 | 299 |
| 300 bool SendSideCongestionController::IsNetworkDown() const { | 300 bool SendSideCongestionController::IsNetworkDown() const { |
| 301 rtc::CritScope cs(&network_state_lock_); | 301 rtc::CritScope cs(&network_state_lock_); |
| 302 return network_state_ == kNetworkDown; | 302 return network_state_ == kNetworkDown; |
| 303 } | 303 } |
| 304 | 304 |
| 305 } // namespace webrtc | 305 } // namespace webrtc |
| OLD | NEW |