Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(124)

Side by Side Diff: net/quic/congestion_control/inter_arrival_sender.h

Issue 15937012: Land Recent QUIC changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Small bug fixes Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_QUIC_CONGESTION_CONTROL_INTER_ARRIVAL_SENDER_H_ 5 #ifndef NET_QUIC_CONGESTION_CONTROL_INTER_ARRIVAL_SENDER_H_
6 #define NET_QUIC_CONGESTION_CONTROL_INTER_ARRIVAL_SENDER_H_ 6 #define NET_QUIC_CONGESTION_CONTROL_INTER_ARRIVAL_SENDER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "net/base/net_export.h" 10 #include "net/base/net_export.h"
11 #include "net/quic/congestion_control/channel_estimator.h" 11 #include "net/quic/congestion_control/channel_estimator.h"
12 #include "net/quic/congestion_control/inter_arrival_bitrate_ramp_up.h" 12 #include "net/quic/congestion_control/inter_arrival_bitrate_ramp_up.h"
13 #include "net/quic/congestion_control/inter_arrival_overuse_detector.h" 13 #include "net/quic/congestion_control/inter_arrival_overuse_detector.h"
14 #include "net/quic/congestion_control/inter_arrival_probe.h" 14 #include "net/quic/congestion_control/inter_arrival_probe.h"
15 #include "net/quic/congestion_control/inter_arrival_state_machine.h" 15 #include "net/quic/congestion_control/inter_arrival_state_machine.h"
16 #include "net/quic/congestion_control/paced_sender.h" 16 #include "net/quic/congestion_control/paced_sender.h"
17 #include "net/quic/congestion_control/send_algorithm_interface.h" 17 #include "net/quic/congestion_control/send_algorithm_interface.h"
18 #include "net/quic/quic_bandwidth.h" 18 #include "net/quic/quic_bandwidth.h"
19 #include "net/quic/quic_clock.h" 19 #include "net/quic/quic_clock.h"
20 #include "net/quic/quic_protocol.h" 20 #include "net/quic/quic_protocol.h"
21 #include "net/quic/quic_time.h" 21 #include "net/quic/quic_time.h"
22 22
23 namespace net { 23 namespace net {
24 24
25 class NET_EXPORT_PRIVATE InterArrivalSender : public SendAlgorithmInterface { 25 class NET_EXPORT_PRIVATE InterArrivalSender : public SendAlgorithmInterface {
26 public: 26 public:
27 explicit InterArrivalSender(const QuicClock* clock); 27 explicit InterArrivalSender(const QuicClock* clock);
28 virtual ~InterArrivalSender(); 28 virtual ~InterArrivalSender();
29 29
30 static QuicBandwidth CalculateSentBandwidth(
31 const SendAlgorithmInterface::SentPacketsMap& sent_packets_map,
32 QuicTime feedback_receive_time);
33
30 // Start implementation of SendAlgorithmInterface. 34 // Start implementation of SendAlgorithmInterface.
31 virtual void OnIncomingQuicCongestionFeedbackFrame( 35 virtual void OnIncomingQuicCongestionFeedbackFrame(
32 const QuicCongestionFeedbackFrame& feedback, 36 const QuicCongestionFeedbackFrame& feedback,
33 QuicTime feedback_receive_time, 37 QuicTime feedback_receive_time,
34 QuicBandwidth sent_bandwidth,
35 const SentPacketsMap& sent_packets) OVERRIDE; 38 const SentPacketsMap& sent_packets) OVERRIDE;
36 39
37 virtual void OnIncomingAck(QuicPacketSequenceNumber acked_sequence_number, 40 virtual void OnIncomingAck(QuicPacketSequenceNumber acked_sequence_number,
38 QuicByteCount acked_bytes, 41 QuicByteCount acked_bytes,
39 QuicTime::Delta rtt) OVERRIDE; 42 QuicTime::Delta rtt) OVERRIDE;
40 43
41 virtual void OnIncomingLoss(QuicTime ack_receive_time) OVERRIDE; 44 virtual void OnIncomingLoss(QuicTime ack_receive_time) OVERRIDE;
42 45
43 virtual void SentPacket(QuicTime sent_time, 46 virtual void SentPacket(QuicTime sent_time,
44 QuicPacketSequenceNumber sequence_number, 47 QuicPacketSequenceNumber sequence_number,
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 BandwidthUsage bandwidth_usage_state_; 89 BandwidthUsage bandwidth_usage_state_;
87 QuicTime back_down_time_; // Time when we decided to back down. 90 QuicTime back_down_time_; // Time when we decided to back down.
88 QuicBandwidth back_down_bandwidth_; // Bandwidth before backing down. 91 QuicBandwidth back_down_bandwidth_; // Bandwidth before backing down.
89 QuicTime::Delta back_down_congestion_delay_; // Delay when backing down. 92 QuicTime::Delta back_down_congestion_delay_; // Delay when backing down.
90 93
91 DISALLOW_COPY_AND_ASSIGN(InterArrivalSender); 94 DISALLOW_COPY_AND_ASSIGN(InterArrivalSender);
92 }; 95 };
93 96
94 } // namespace net 97 } // namespace net
95 #endif // NET_QUIC_CONGESTION_CONTROL_INTER_ARRIVAL_SENDER_H_ 98 #endif // NET_QUIC_CONGESTION_CONTROL_INTER_ARRIVAL_SENDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698